Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by EternallyCurious. 04/25/24 10:20
Trading Journey
by howardR. 04/24/24 20:04
M1 Oversampling
by Petra. 04/24/24 10:34
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Scripts not found
by juergen_wue. 04/20/24 18:51
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
folder management functions
by VoroneTZ. 04/17/24 06:52
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, SBGuy, Petra), 801 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Mega_Rod, EternallyCurious, howardR, 11honza11, ccorrea
19048 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Doing 2 things at the same time with if function #447606
12/21/14 17:18
12/21/14 17:18
Joined: Apr 2014
Posts: 23
M
Mothership Offline OP
Newbie
Mothership  Offline OP
Newbie
M

Joined: Apr 2014
Posts: 23
Hey!

What should I type if I want my script to do 2 things if something happens. Say that I want to place 1 long trade and 1 short trade when 2 MAs crosses.

I don't seem to get it to work by typing the following:


If(crossOver(MA1,MA2))
enterLong();
enterShort();

Re: Doing 2 things at the same time with if function [Re: Mothership] #447608
12/21/14 18:30
12/21/14 18:30
Joined: Jun 2013
Posts: 1,609
D
DdlV Offline
Serious User
DdlV  Offline
Serious User
D

Joined: Jun 2013
Posts: 1,609
Hi Mothership. Your code associates only the enterLong with the if. Try {}.

HTH.


Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1