Unable to use a second instrument in BollingerBands study

Aionda

Member
Joined
Dec 26, 2022
Posts
17
Likes
1
I downloaded the SDK source code of all studies, then I cloned the BollingerBands study.
I added a second instrument inside the study in

I set in @StudyHeader the parameter multipleInstrument=true.

In the code I added a second input field for the second instrument:
@Override
public void initialize(Defaults defaults)
{
....
inputs.addRow(new InstrumentDescriptor(Inputs.INSTRUMENT2, get("LBL_INSTRUMENT2")));

The whole study is no more working, whatever I do:

The Bollinger Bands are disappearing.

I even created to separate input fields for two different instruments, updated the code to fetch values from the first instrument.
It's impossible to run the Bollinger Band if there is a second instrument as input field.

Even in the Debug window I no more see my log entries. It seems that the study internally crashes?
 

Attachments

  • Bildschirm­foto 2022-12-26 um 15.12.05.png
    Bildschirm­foto 2022-12-26 um 15.12.05.png
    391.2 KB · Views: 4
  • Bildschirm­foto 2022-12-26 um 15.12.30.png
    Bildschirm­foto 2022-12-26 um 15.12.30.png
    454 KB · Views: 4
Top