How to reach the working instances of the bot(s) from the indicator?
Created at 16 Dec 2021, 17:33
How to reach the working instances of the bot(s) from the indicator?
16 Dec 2021, 17:33
Hello,
The bot class has a public static member. Assume it is a counter the bot increases from time to time.
The only instance of the bot is working for simplicity.
I can add the reference to the bot assembly to the indicator of course.
How to access the instance of this counter from the indicator on a different chart?
It is possible to create the shared file in the memory, of course. The question is about accessing of the instance of the bot from the indicator on the different chart.
Regards,
amusleh
17 Dec 2021, 09:20
Hi,
No, you can't access a cBot from another indicator running on another chart.
But you can communicate with a cBot and indicator running on two different charts via .NET named pipe.
The .NET named pipe is the right solution for your problem, but you have other options too:
@amusleh