
04-26-2008, 12:53 PM
|
|
Senior Member
|
|
Join Date: Feb 2006
Posts: 559
|
|
I think you should have a solution here : MetaTrader FTP client!
Quote:
Originally Posted by sandfromsky
bool SendFTP( string filename, string ftp_path=NULL)
Sends the file to the FTP server set in the Tools->Options->Publisher tab. If the attempt fails, it retuns FALSE.
The function does not operate in the testing mode. This function cannot be called from custom indicators, either.
When SendFTP in custom indicators, it's can't work, but can in scripts.
I tried your method, put my function into a .mph file, and save it into experts\include, it result error No. 4055.
TestFTPInc.mqh
int FTPTest()
{
SendFTP("shots\\" + Symbol() + "_5m_live.gif", NULL);
Alert(GetLastError());
return(0);
}
In my custom indicators, I call it like
if (IsNewBar())
{
WindowScreenShot("shots\\" + Symbol() + "_5m_live.gif", 640, 480);
FTPTest();
}
it result error No. 4055.
Thanks a lot. Have a happy weekend.
|
|