I will try with the code on the MACD Crossover.
On the other hand, about on how executing a code for any indicator you may find it out at community indicators and click on files; there it is possible to modify and share.
Me I do use MACD, ADI, Elder and several charts; renko, points and figures to determine the tendency. I honestly works very fine to me.