How to check if file is updated completely or not?

 
How I can check it the file was completely updated and not used by any other program? How I can let any other program access the file to overwrite for updation in MQL?
 

Use of a Token.

He who has it can modify.

 
Marco vd Heijden:

Use of a Token.

He who has it can modify.

I didn't understood it sir.... Can you please guide me? 

 

We have a flag that say's "BUSY" now when i give the flag to you, you wave it to me showing that you are busy and that you are the only one allowed to talk.

When you are finished, you give the flag to me, so i can wave it around showing everybody hey be silent i am the only one allowed to speak.

When i am done i pass the flag to the next person in the ring that could want to have something to say.


What part do you not understand ?

 
Marco vd Heijden:

We have a flag that say's "BUSY" now when i give the flag to you, you wave it to me showing that you are busy and that you are the only one allowed to talk.

When you are finished, you give the flag to me, so i can wave it around showing everybody hey be silent i am the only one allowed to speak.

When i am done i pass the flag to the next person in the ring that could want to have something to say.


What part do you not understand ?

Actually I didn't understood how I can apply this technique in MQL5. I cannot find anything in correlation to this technique. Please can you hep me out, sir?

Reason: