Mohsen Farghadani / Publications
Forum
mql5 different behavior of iMA() function in script and in custom indicator
hi this code is mql5 script and print the ma value of D1 period and work as it expected: void OnStart () { int mahandle; mahandle= iMA ( NULL , PERIOD_D1 , 1 , 0 , MODE_SMA , PRICE_MEDIAN ); double mavalue[ 1 ]; CopyBuffer (mahandle, 0 , 0 , 1 ,mavalue); Print (mavalue[ 0 ]); } but same