Bulletproofing broker-to-MC connection issues

Questions about MultiCharts and user contributed studies.
champski
Posts: 71
Joined: 28 Jun 2011
Has thanked: 20 times
Been thanked: 1 time

Bulletproofing broker-to-MC connection issues

Postby champski » 20 Jun 2013

Hi,

I would like to know how to make my automated system bulletproof from broker-to-MC connection issues.

Is there a way I can (maybe via easy language) re-enable automated order execution, in the event there is a connection issue which causes the broker connection to hang in a 'connecting' status (or similar cause)?

i.e.
if brokerconnection "LMAX" status <> "connected" then
set brokerconnection "LMAX" status = disconnect ;
set brokerconnection "LMAX" status = connect ;
end

If anyone has other similar ideas or ways of going about this, please share.

Cheers
Champski

User avatar
Andrew MultiCharts
Posts: 1587
Joined: 11 Oct 2011
Has thanked: 931 times
Been thanked: 559 times

Re: Bulletproofing broker-to-MC connection issues

Postby Andrew MultiCharts » 25 Jun 2013

Hello Champski,

You can try the following code in MultiCharts 8.7 beta 2 or any later version, but you will still have to click on "Yes" button in the warning message window when automation is turned on from script. There is no 100% automated solution for this case at the moment.

Code: Select all

Vars: Var1(0);

If getappinfo(aiStrategyAuto) = 1 then
var1 = 1;

If getappinfo(aiStrategyAuto) <> var1 then CommandLine(".at_toggle");


Return to “MultiCharts”