Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (howardR), 1,065 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 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