Any questions from a PROFI to a SUPER PROFI - 1. - page 32

 

And yes, it's not UB in C++ after all.

But in any case, combining dependent function things in parameters is a bad programming style.

 

There is an EA trading on a desktop computer. Question: how, without access to a computer, can I stop the EA from working?

P.s. I have found only one option - to add to the EA a block that checks for the presence of a limit order on some exotic pair... if it finds one, it deletes it and stops the EA. And the Limit order may be set by phone in case of emergency... But maybe there are other options?

 

with a limit-sheet is a reliable option, use it.

Sometimes they add additional information for the expert to the price or the commentary on the limit.

 

Just terminate the EA, by internal condition?
Just left this thread, might fit... ))

https://www.mql5.com/ru/forum/112689

 
sergeev:

Sometimes additional information is added to the price or the commentary on the limit for the examiner.

Yeah, magik + comment.
 
TheXpert:
Yep, magik + comment.

Andrey, I'm telling you the truth. I had an order long ago in which a person asked me to make three limits.

- one for switching an EA on/off
- in the second one, the last 4 prices contained the current time given by the EA. i.e. it was checked whether the EA was working or not
- in the third one, 5 parameters were contained in each price figure, according to which the EA should work.

The Magik has been used as usual for the accession to the orders.

 
sergeev:

magik served as usual for belonging to their orders.

I would use the magik to determine the assignment, and write additional information in the commentary.
 

The issue of resizing the open file mapping upwards has been raised somewhere, possibly here.

The size is changed by calling CreateFileMapping() again with the same name and a new size, but it cannot be more than 8196 bytes! Experimentally obtained.

I.e. it's not possible to resize a larger mapping. But, from 0 to 8196 it works.

Maybe someone knows, there is a way to resize it without reopening file mapping?

 

http://www.delphisources.ru/pages/faq/base/filemapping.html


function CreateFileMapping(hFile: THandle; lpFileMappingAttributes: PSecurityAttributes; flProtect, dwMaximumSizeHigh, dwMaximumSizeLow: DWORD; lpName: PChar): THandle;

dwMaximumSizeHigh - the most 64-bit value of the size of the allocated memory size for shared access (more than 4 Gbt)- we don't need so much :) - Let's assign value 0 to this argument.

dwMaximumSizeLow - Thanks to the nice inhabitants of the Kingdom who pointed out the error in the description of this argument! Especially Mr. Uno who explained it very well! (see comment to the article) - the lower 64-bit value of shared memory size - if dwMaximumSizeHigh equals 0, the size of this argument must be at least SIZE OF DATA to be placed in the swap file. Notethat Intel "page" size is 4 KBt, i.e. if you specify 1 byte, you get a "pocket for sharing" :) 4 KBt, if you specify 4001, you can put up to 8Kbt of data into the file mapping object, etc.

 

in general the page is 64 kb. why it makes 8 is unclear. not deljon.

http://wm-help.net/books-online/book/59464/59464-10.html