If you need assistance with your cBot, you would need to provide at least the following information
What is the cBot supposed to do?
What does it do instead?
What is the exact problem you are trying to solve?
Best regards,
Panagiotis
Hello Panagiotis and thanks for getting back to me
Ive been working too long on trying to fix the cBot, my brain was fried and I completely missed providing more information. Sorry about that. And pardon the messy look of the code. I used the “code” function, hope you can read it anyways.
- The major issue is that its not performing any Buys or Sells. Im not even sure if its the code or my settings for the demo account. The Log messages reads:
When switching tabs, the configured settings are lost, which is quite inconvenient, as it requires reconfiguration every time. Is it possible to fix this in the new cTrader update?
Hi there,
Unfortunately we cannot reproduce such a behavior in the latest version. Can you record a video capturing the entire UI area and the exact steps to reproduce the problem?
Best regards,
Panagiotis
(I apologize for my poor language skills) I want to see the latest open positions and the latest closed positions. To do this, they should be positioned at the top of the window - within the visible area. But when I switch windows, the sorting disappears...
When switching tabs, the configured settings are lost, which is quite inconvenient, as it requires reconfiguration every time. Is it possible to fix this in the new cTrader update?
Hi there,
Unfortunately we cannot reproduce such a behavior in the latest version. Can you record a video capturing the entire UI area and the exact steps to reproduce the problem?
The values you provided are not for each tick but for each bar since the Calculate() method is called for every bar for historical bars. At the moment I see nothing wrong.
Best regards,
Panagiotis
I just want the value of just 1 bar , that either being the current or previous , how do I achieve that ?
Hi there,
I am a bit confused about what the issue is now. You said that the values do not make sense to you but they seem to make sense to. I have ask for an explanation of what exact value would you expect instead of the ones you see printed and how that value is calculated but you did not provide it (e.g. the value printed at 12:00 is 1 but I would expect it to be 2 because a, b, c….). It is hard to help you further without this information.
Best regards,
Panagiotis
When I run this : var currentprice = Bars.ClosePrices[index-1];
I just expect to get the value of the currentprice or the price of the bar before that but as you are saying its giving me the value of every single bar starting from bar 1 , I don't want that , I just want the price of the previous bar so that I can minus it with Something Like S1 and get a pip value which is the distance between the current price and S1
Hi there,
Then you can use the IsLastBar property to print the values only for the last bar.
The values you provided are not for each tick but for each bar since the Calculate() method is called for every bar for historical bars. At the moment I see nothing wrong.
Best regards,
Panagiotis
I just want the value of just 1 bar , that either being the current or previous , how do I achieve that ?
Hi there,
I am a bit confused about what the issue is now. You said that the values do not make sense to you but they seem to make sense to. I have ask for an explanation of what exact value would you expect instead of the ones you see printed and how that value is calculated but you did not provide it (e.g. the value printed at 12:00 is 1 but I would expect it to be 2 because a, b, c….). It is hard to help you further without this information.
The values you provided are not for each tick but for each bar since the Calculate() method is called for every bar for historical bars. At the moment I see nothing wrong.
The close price changes on every tick therefore it is expected that the results would change. Can you explain to us what your expectation is?
Best regards,
Panagiotis
No I understand why it would be different at every tick but the way its different makes I unusable , I expect the numbers printing to be somewhat close to each other instead they are not, they are widely different with it even printing “NaN”
It's obviously a logical bug on your side but it's hard to tell by a code snippet. We are just guessing. You would need to provide more information in order to get more help. Post at least the following
The full indicator code
Screenshots of the values you get.
The values you would expect to get instead and an explanation why you expect them.
The close price changes on every tick therefore it is expected that the results would change. Can you explain to us what your expectation is?
Best regards,
Panagiotis
No I understand why it would be different at every tick but the way its different makes I unusable , I expect the numbers printing to be somewhat close to each other instead they are not, they are widely different with it even printing “NaN”
It's obviously a logical bug on your side but it's hard to tell by a code snippet. We are just guessing. You would need to provide more information in order to get more help. Post at least the following
The full indicator code
Screenshots of the values you get.
The values you would expect to get instead and an explanation why you expect them.
PanagiotisCharalampous
10 Jan 2024, 07:32
Hi there,
You receive them because you have an account with the specific broker. You should contact the broker if you want them to be disabled.
Best regards,
Panagiotis
@PanagiotisCharalampous