Thread: How to code?
View Single Post
  #1168 (permalink)  
Old 08-18-2008, 12:53 PM
fercan fercan is offline
Member
 
Join Date: Aug 2008
Posts: 36
fercan is on a distinguished road
Quote:
i have created a really simple EA. and a system which i use in atleast 3 Timeframe..May problem it doesn't stop opening and i don't want to have 3 EA and 3 chart for one pair.

i need a code that would only do one order for buy and for sell per bar per TF and still open if it is on a different bar. i can have buy and sell and the same bar.

Sometimes i have 3 signal in 3 different TF. i want to take all order but i want only one order per TF and i can still take another order in another TF if it is still open but in a different bar.

example:
1 signal in 4h
1 signal in 1h but it falls in bar for 4h
1 signal in 30 min but only one bar for 1h and 4h.
3 signal will be open.

i am ok with using magic number as means of filter.

can someone help me? thank you very much.

so far this is what i thought:
for 30 mins
if (magicnumber == 123)
{
if (iTime(OrderOpenTime()) != iTime(Symbol(),PERIOD_M30,0))
{//my order code}

}

i don't have MT4 but i know somethings is not right in the logic or code. So guys please help me.

also i think we have similar problem with matrixebiz
Can anyone help me please?
Reply With Quote