icustom()... Is this the way to do it?

 

Hey all! im a noob and my first project is to build an EA out of an indicator (I guess im not the only one starting that way hehehe)


After hours of research, I found that the indicator will put its "little arrows and crosses" indicating when to buy or sell every time one of this if statements is true:


if (i==hhb)  b1[i]=High[hhb] +tr;

if (i==llb)  b2[i]=Low[llb]  -tr;

if (i==hhb1) b3[i]=High[hhb1]+tr/2;

if (i==llb1) b4[i]=Low[llb1] -tr/2;


Now, how do I get my EA to give an order to buy or sell whenever any "arrow or cross" is drawn by the indicator??

I have read over the internet that the icustom() function would do it, but have been playing with it and this

and I still dont get it to work...


Thankyou guys!!!