Compiling from within an indicator or EA?

 

Might seem like a daft question, but is it possible to compile an indicator or EA from within itself.... I have been building a custom indicator which changes some of it's settings as it goes, and the only way to get it to update in the terminal is to keep compiling it in the editor. I have tried everything but this seems like the only way around it.


Cheers,


FB

 

I think you are likely to be barking up the wrong tree here and making things more difficult for yourself than they should be.

I don't think its a good idea to have an EA try to change its own source code, recompile itself etc. In any case, it would need also to reinitialise itself too.

What about version control?

What about rigorous testing/reliability?

Will you recognise your source code the next time you try to maintain it?


What is it you are trying to achieve when you say "a custom indicator which changes some of it's settings as it goes"?


CB

 
Write the settings to a file, read it back in on init().
Reason: