Hi,
Is it possible somehowe to identify what instrumnet the script is running on in the code?
My idea is to have one script running on for example on both DAX and FTSE (or 5 more indexes) but with different parameters. If there woule be a “constant” for example INSTRUMENT I could to this:
if INSTRUMENT="DAX" then
param1=45
endif
if INSTRUMNET="FTSE" then
param1 = 50
endif
Now I have to duplicate the script for every instrument I want to use it on. It is allot of work to update all copies of the script if I make improvements on it.
//Jonas
I think you can’t, at least I could not find a way to do it.
You have to duplicate your strategy as many times you wish, naming them differently according to the instrument chosen for each one of them.
Roberto
In ProBuilder language, variables can’t handle string. There is also no instruction to retrieve the current instrument from the broker’s server.
A rough idea would be to test the current price and/or the pointsize to know which instrument you are currently using.