I have a query with regards to coding in PT3 using C#.
Chart 1- EURUSD
chart 2 - GBPUSD
chart 3 - USDJPY
3 different charts with the same indicator ('md') loaded on each of the charts.
-indicator md is an indicator coded in C# for the PT3 platform.
-each instance of indicator md has 2 variables VA and VB, used to output/'setvalue' for 2 lines on the md indicator.
What I would like to do -
create a new indicator (sum md) on a different chart that gets values of VA and VB from the 3 respective charts i.e. EURUSD, GBPUSD and USDJPY.
And do some calculations and output the result on the new indicator sum md.
sum md line 1 = VA(from EURUSD) + VA(from GBPUSD) + VA(from USDJPY)
sum md line 2 = VB(from EURUSD) + VB(from GBPUSD) + VB(from USDJPY)
sum md line 3 = (sum md line 1 - sum md line 2)
In the above case what would the syntax/code be for getting the values of the variables VA and VB from the 'md' indicators on the different charts (3 of them ) and into the new indicator 'sum md' ?
Would appreciate any help for this query or a PT3 C# example that shows how this can be done.