FilesExist - check if a file exists in web folder

 

Here:

http://docs.mql4.com/files/fileisexist

There are the instruction to handle files (down/up, read-writhe ...)

I'm trying to code this to check if a file exists in web folder...

Any idea how to do that?


Regards,

FileIsExist - MQL4 Documentation
  • docs.mql4.com
FileIsExist - MQL4 Documentation
 
Rubens Marinho:

Here:

http://docs.mql4.com/files/fileisexist

There are the instruction to handle files (down/up, read-writhe ...)

I'm trying to code this to check if a file exists in web folder...

Any idea how to do that?


Regards,

What is "web folder" ?

Anyway, mql4 file functions only work in the sandbox : all what is under MQL4\Files

 

I mean with a web folder:

http://www.domain.com/folder/file.bak


The idea is verify if a file exists in web folder, and, if yes the EA will grant the trades, for example:

//+------------------------------------------------------------------+
//|                                                                Sample.mq4 |
//|           Copyright 2005-2015, MetaQuotes Software Corp. |
//|                                                   http://www.mql4.com |
//+------------------------------------------------------------------+
#property copyright   "2005-2015, MetaQuotes Software Corp."
#property link        "http://www.mql4.com"

extern string file_user = "file.bak";


int start() {


if (  file_user()!= http://www.domain.com/folder/)
   {
    Alert("WRONG FILE!");
   return;
   }


And my doubt is, how can I check that?

MQL4: automated forex trading, strategy tester and custom indicators with MetaTrader
  • www.mql4.com
MQL4: automated forex trading, strategy tester and custom indicators with MetaTrader
 
You have to use WebRequest().
 

Yes, I saw and tried here:

http://docs.mql4.com/common/webrequest

But, I wasn't able to code it... could you please help me?

WebRequest - MQL4 Documentation
  • docs.mql4.com
WebRequest - MQL4 Documentation
 
Reason: