Programmatically Start and Stop another Calgo?
Programmatically Start and Stop another Calgo?
18 Sep 2016, 06:52
I want to create a bot that will automatically start and stop another bot.
Is this possible?
I know I can just copy and paste the code of the second bot inside the first bot to achieve the same effect, but I figured it would be much more neat to be able to have bots 'call' other bots like functions.
Replies
driftingprogrammer
13 Mar 2020, 03:30
Is this still the only solution
lucian said:
One cBot create a folder:
[Parameter(DefaultValue = C:)] public string drive { get; set; } protected override void OnTick() {if (something) { string path = drive + ":/StartXcBot"; System.IO.Directory.CreateDirectory(path); } }and XcBot read if folder exist:
[Parameter(DefaultValue = C:)] public string drive { get; set; } protected override void OnTick() { string path = drive + ":/StartXcBot"; if (System.IO.Directory.Exists(path)) { do something } }
Is this still the best way, somebody mentioned on the chat room that there is now an API to invoke a cbot from another cbot, and it seems there is also a way to pass the parameter file.
The problem is i cannot use the above solution since the cbot i am invoking is a third party cbot.
Thanks.
@driftingprogrammer
PanagiotisCharalampous
13 Mar 2020, 08:51
Hi driftingprogrammer,
There is no such feature in the API at the moment.
Best Regards,
Panagiotis
@PanagiotisCharalampous
... Deleted by UFO ...