Just wanted to submit bug report. When chart has multiple data lines, under rare scenarios I have seen where Bars.LastBarOnChart will return false all the time. When debugging, I found out that in such case Bars.Status=None, and only one of the other data lines (say line 3) that has BarsOfData(3).Status=Close will have BarsOfData(3).LastBarOnChart=True. All other data lines will be reporting LastBarOnChart=False
I am running latest version 9.0 build 11212
This is a bug because if indicator is designed to be looking at just one data line, given by Bars, it will not be reporting LastBarOnChart properly.
Thanks,
Dave
LastBarOnChart not working with multiple data lines
- Henry MultiСharts
- Posts: 9165
- Joined: 25 Aug 2011
- Has thanked: 1264 times
- Been thanked: 2956 times
- Henry MultiСharts
- Posts: 9165
- Joined: 25 Aug 2011
- Has thanked: 1264 times
- Been thanked: 2956 times
Re: LastBarOnChart not working with multiple data lines
Hello Dave,
We were unable to replicate this behavior on our end.
Please send us (support@multicharts.com) the following information for further analysis:
- workspace you are using;
- in QuoteManager select the symbols you are using, make a right click on it->Export data->Export instrument (without data). Send us the QMD export file for analysis;
- in PowerLanguage .NET editor->File->Export->export the studies you are using for replicating this behavior; send us the pln file;
- instructions for replicating the error.
We were unable to replicate this behavior on our end.
Please send us (support@multicharts.com) the following information for further analysis:
- workspace you are using;
- in QuoteManager select the symbols you are using, make a right click on it->Export data->Export instrument (without data). Send us the QMD export file for analysis;
- in PowerLanguage .NET editor->File->Export->export the studies you are using for replicating this behavior; send us the pln file;
- instructions for replicating the error.
Re: LastBarOnChart not working with multiple data lines
this does happen, look at the below situation:
https://ibb.co/NKFjh7D
What needs to happen is add some instruments in the same chart such that their sessions do not fully overlap. Then wait for that day time where the non-principal instruments (data2 or data3) are "ahead" of the main one (data1) - during that time interval, LastBarOnChart will ALWAYS return FALSE for data1 - which is messing up any strategies relying on LastBarOnChart.
This should definitely be fixed
https://ibb.co/NKFjh7D
What needs to happen is add some instruments in the same chart such that their sessions do not fully overlap. Then wait for that day time where the non-principal instruments (data2 or data3) are "ahead" of the main one (data1) - during that time interval, LastBarOnChart will ALWAYS return FALSE for data1 - which is messing up any strategies relying on LastBarOnChart.
This should definitely be fixed
- Vlada MultiCharts
- Posts: 267
- Joined: 22 Apr 2020
- Has thanked: 8 times
- Been thanked: 62 times
Re: LastBarOnChart not working with multiple data lines
Hello andrei,this does happen, look at the below situation:
https://ibb.co/NKFjh7D
What needs to happen is add some instruments in the same chart such that their sessions do not fully overlap. Then wait for that day time where the non-principal instruments (data2 or data3) are "ahead" of the main one (data1) - during that time interval, LastBarOnChart will ALWAYS return FALSE for data1 - which is messing up any strategies relying on LastBarOnChart.
This should definitely be fixed
Unfortunately, we did not manage to reproduce the behavior according to your instruction. Please see the attached screenshot. The yellow plot equals 1 if LastBarOnChart = True
If you want us to look into this matter, please reproduce the issue and send us the following:
1. The log files.
2. The study in PLA format.
3. The workspace file
- Attachments
-
- image (1).png
- (24.03 KiB) Not downloaded yet