Forum

Array out of range

Whats my problem? input int cn= 100 ; double lowP[]; void OnInit () { for ( int i= 1 ;i<=cn;i++) { lowP[i- 1 ]= iLow ( Symbol (), 60 ,i); } Comment (lowP[ 0 ], "\n" ,lowP[ 1 ], "\n" ,lowP[ 2 ]); } show this

Working OrderClose in demo and real accounts

Hello These codes consist of two keys, the first key closes half of the first open trade and the second key closes completely. The keys work in the demo account but do not work in the real account. Please help me, What's problem?! void OnTick () { ButtonCreate( 0 , "closeHalf" , 0 , 10 , 350