Errors, bugs, questions - page 1097

 
Zeleniy:


...

To make hibernation unavailable, follow these steps:
  1. Click the Start button and enter cmd in the Start search box.
  2. In the search results list, right-click Command Prompt and select Run as administrator.
  3. When you are prompted for user account-based control, click Continue.
  4. At the command prompt type powercfg.exe /hibernate off and press Enter.
  5. Type exit and press Enter to exit the command line.
To make hibernation available, carry out the following steps:
  1. Click the Start button and type cmd in the Start search box.
  2. Right-click Command Prompt in the search result list and select Run as administrator.
  3. When you are prompted for user account-based control, click Continue.
  4. At the command prompt type powercfg.exe /hibernate on and press Enter.
  5. Type exit and press Enter to exit the command line.
 

powercfg.exe -h off


 
A100:
For example, forcing the script to terminate

ExpertRemove?

 
stringo:

ExpertRemove?

ExpertRemove - does not stop script execution, or many operations have time to execute before stopping, or causes the script to freeze

zero divide - always stops the script from the moment it appears

 
A100:

ExpertRemove - does not stop script execution, or many operations have time to execute before stopping, or causes the script to freeze

I had the same symptoms once. then i fixed the code in the deinit phase. - Everything works.

Look for problems in your code. you are not analyzing the halt.

 
stringo:

ExpertRemove?

Slava, why isn't there an analogue for indicators? I, for example, really need one. Is it a principal idea, or is it just lazy to do it?

 
sergeev:

I used to have the same symptoms. then I tweaked the code in the deinit phase. - It all worked.

MQL5 Reference Guide: For scripts the Deinit event is not generated and thereforethe OnDeinit() function cannot be used in scripts.
Документация по MQL5: Основы языка / Функции / Функции обработки событий
Документация по MQL5: Основы языка / Функции / Функции обработки событий
  • www.mql5.com
Основы языка / Функции / Функции обработки событий - Документация по MQL5
 
MetaDriver:

Slava, why isn't there an analogue for the indicators? I, for example, really need one. Is it a principal idea, or is it just lazy to do it?

Instead of ExpertRemove(), they would make a universal functionProgramRemove().
 
tol64:
Instead of ExpertRemove(), they would make a universalProgramRemove() function.

there is a standard C language equivalent: exit

Consider

 
A100:
MQL5 Reference Manual: Deinit event is not generated for scripts and thereforeOnDeinit() cannot be used in scripts.
well yeah, i had an exp.
Reason: