I am building an indicator which there are slightly different requirements for each stock index (i.e. ASX, DAX, NQ, etc.). Within ProRealTime, is there the ability in the coding to be able to confirm the instrument that is loaded on the chart?
For example
if ASX is loaded, then ‘do this’
or
if DAX is loaded, then ‘do that’
I know in TradingView this can be done, just not sure on ProRealTime.
Actually you could do this manually, by adding a variable to be set from the indicator’s properties, say ranging from 0 to 5 (or any greater value of your choice):
1
2
3
4
5
6
7
8
9
10
11
12
MyAsset=0//0=Dax, 1=Asx, 2=EurGbp,…
IfMyAsset=0then
.
ElsifMyAsset=1then
.
ElsifMyAsset=2then
.
ElsifMyAsset=3then
.
.
.
Endif
when you add it to a chart you can simply change that value from the properties.
You will have to keep a paper list of the chosen assets and their codes next to your PC.
To help us continually offer you the best experience on ProRealCode, we use cookies. By clicking on "Continue" you are agreeing to our use of them. You can also check our "privacy policy" page for more information.Continue