Download MetaTrader 5

Error with no description

To add comments, please log in or register
Marcelo Coutinho
1161
Marcelo Coutinho  

Hi There !

Can someone please help me getting more information about this message ?

JG 0 22:10:32.215 YouBotG2 (WINQ14,M1) OnDeinit_Uninitalization reason code = 9

DH 0 22:10:32.215 YouBotG2 (WINQ14,M1) OnDeinit_UninitReason = Another reason

DQ 0 22:10:32.215 YouBotG2 (WDON14,M15) OnDeinit_Uninitalization reason code = 9

HF 0 22:10:32.215 YouBotG2 (WDON14,M15) OnDeinit_UninitReason = Another reason 

Regards,

MRC 

Olawale Adenagbe
4942
Olawale Adenagbe  

The link below will provide useful information

https://docs.mql4.com/constants/namedconstants/uninit 

You may need to further develop the getUninitReasonText function if you want it to print the description of all the reason codes.

Cheers. 

Uninitialization Reason Codes - MQL4 Documentation
  • docs.mql4.com
Uninitialization Reason Codes - MQL4 Documentation
Alain Verleyen
Moderator
31189
Alain Verleyen  
verdure:

The link below will provide useful information

https://docs.mql4.com/constants/namedconstants/uninit 

You may need to further develop the getUninitReasonText function if you want it to print the description of all the reason codes.

Cheers. 

The question was about mql5.
Alain Verleyen
Moderator
31189
Alain Verleyen  
YouTrade:

Hi There !

Can someone please help me getting more information about this message ?

JG 0 22:10:32.215 YouBotG2 (WINQ14,M1) OnDeinit_Uninitalization reason code = 9

DH 0 22:10:32.215 YouBotG2 (WINQ14,M1) OnDeinit_UninitReason = Another reason

DQ 0 22:10:32.215 YouBotG2 (WDON14,M15) OnDeinit_Uninitalization reason code = 9

HF 0 22:10:32.215 YouBotG2 (WDON14,M15) OnDeinit_UninitReason = Another reason 

Regards,

MRC 

These message are printed by your code, not ?
Marcelo Coutinho
1161
Marcelo Coutinho  
angevoyageur:
These message are printed by your code, not ?

Yes ... printed by my code ... what can I do please ?

 

void OnDeinit(const int reason)
  {
//--- The first way to get the uninitialization reason code
   Print(__FUNCTION__,"_Uninitalization reason code = ",reason);
//--- The second way to get the uninitialization reason code
   Print(__FUNCTION__,"_UninitReason = ",getUninitReasonText(_UninitReason));

  }

string getUninitReasonText(int reasonCode)
  {
   string text="";
   switch(reasonCode)
     {
      case REASON_ACCOUNT:
         text="Account was changed";break;
      case REASON_CHARTCHANGE:
         text="Symbol or timeframe was changed";break;
      case REASON_CHARTCLOSE:
         text="Chart was closed";break;
      case REASON_PARAMETERS:
         text="Input-parameter was changed";break;
      case REASON_RECOMPILE:
         text="Program "+__FILE__+" was recompiled";break;
      case REASON_REMOVE:
         text="Program "+__FILE__+" was removed from chart";break;
      case REASON_TEMPLATE:
         text="New template was applied to chart";break;
      default:text="Another reason";
     }
   return text;
  }
Marcelo Coutinho
1161
Marcelo Coutinho  
verdure:

The link below will provide useful information

https://docs.mql4.com/constants/namedconstants/uninit 

You may need to further develop the getUninitReasonText function if you want it to print the description of all the reason codes.

Cheers. 

Thank you ... see above... I am already using it !

Any ideas ?

Alain Verleyen
Moderator
31189
Alain Verleyen  
YouTrade:

Hi There !

Can someone please help me getting more information about this message ?

JG 0 22:10:32.215 YouBotG2 (WINQ14,M1) OnDeinit_Uninitalization reason code = 9

DH 0 22:10:32.215 YouBotG2 (WINQ14,M1) OnDeinit_UninitReason = Another reason

DQ 0 22:10:32.215 YouBotG2 (WDON14,M15) OnDeinit_Uninitalization reason code = 9

HF 0 22:10:32.215 YouBotG2 (WDON14,M15) OnDeinit_UninitReason = Another reason 

Regards,

MRC 


REASON_CLOSE

9

Terminal has been closed

Marcelo Coutinho
1161
Marcelo Coutinho  
angevoyageur:

REASON_CLOSE

9

Terminal has been closed

Thank you very much. Now I need to understand why ?

Thank you 

To add comments, please log in or register