MQL4 - automated forex trading   /  

Forum

iCustom addressing buffers

Back to topics list To post a new topic, please log in or register

avatar
39
england33 2011.11.27 02:14 

I'm sure this has been answered before but I've searched and can not find the answer.

How is a buffer value addressed/accessed through iCustom? say if I want to get information

out of buffer 0 or buffer 1 of an indicator.

Testing Visualization: Manual Trading

Testing Visualization: Manual Trading

Testing manual strategies on history. Check how your trading algorithm works turning a deaf ear to programming niceties!


avatar
4328
WHRoeder 2011.11.27 03:22 
england33:
out of buffer 0 or buffer 1 of an indicator.

double iCustom( string symbol, int timeframe, string name, ..., int mode, int shift)

mode - Line index. Can be from 0 to 7 and must correspond with the index used by one of SetIndexBuffer functions.
x

avatar
39
england33 2011.11.27 04:32 
WHRoeder:

double iCustom( string symbol, int timeframe, string name, ..., int mode, int shift)

mode - Line index. Can be from 0 to 7 and must correspond with the index used by one of SetIndexBuffer functions.
x

You're kidding me? it was right in front of my face... oh man sorry for wasting your time. Thank you for your help. I'll look better next time....

avatar
39
england33 2011.11.27 04:35 

avatar
39
england33 2011.11.27 05:13 
WHRoeder:

double iCustom( string symbol, int timeframe, string name, ..., int mode, int shift)

mode - Line index. Can be from 0 to 7 and must correspond with the index used by one of SetIndexBuffer functions.
x

Oh wait one more question my master? How do I address/get the value of a previous buffer with iCustom. I tried declaring a variable

of double type that pointed to iCustom but I get an error.

double a = iCustom(NULL, 0, "example",0,0);

string xx1 = DoubleToStr(a[1], Digits);

//this produces an error of unexpected token error unless i remove the [1] but that gives me the current value only.

//i need the previous buffer value.


avatar
39
england33 2011.11.27 05:54 
england33:

Oh wait one more question my master? How do I address/get the value of a previous buffer with iCustom. I tried declaring a variable

of double type that pointed to iCustom but I get an error.

double a = iCustom(NULL, 0, "example",0,0);

string xx1 = DoubleToStr(a[1], Digits);

//this produces an error of unexpected token error unless i remove the [1] but that gives me the current value only.

//i need the previous buffer value.



ah i get it i think. .never mind I think i have it figured out.




avatar
4224
RaptorUK 2011.11.27 10:30 
england33:

Oh wait one more question my master? How do I address/get the value of a previous buffer with iCustom. I tried declaring a variable

The last value passed to iCustom is the shift value . . .
Back to topics list  

To add comments, please log in or register