How to disable signal copying by an EA.

 

I am developing an EA to take over when signal copying run into trouble. I need to disable the copying to do this but I keep getting error 4060 (Function not confirmed). Below are the lines I used to try it. Any help will be appreciated.


    long Flag = SignalInfoGetInteger(SIGNAL_INFO_SUBSCRIPTION_ENABLED);

   Alert (Flag);

 

   bool Flag2 = SignalInfoSetInteger(SIGNAL_INFO_SUBSCRIPTION_ENABLED, 0);

   Alert ("Flag2 =", Flag2);

   Alert ("Error ", GetLastError());

Reason: