I'm trying to find a script which all it does is takes the value of the equity on your account and uploads it on the internet or at least saves it in such a way that it can be stored in a database. Is this possible?
Where to find the Basic Script EA's and Indicators for MT5 3 replies
Basic Alt Key/Entry Script - Simplest Script Ever 1 reply
Need help using a script (basic)... 2 replies
Making Money and the Most Basic of All Basic Strategies 42 replies
Really basic question about a Script 6 replies
bool logAndUploadEquity() {
static string sFile = "Equity.csv";
int iFile;
string sTimestamp;
string sEquity;
// if file couldn't be opened, return false
iFile = FileOpen(sFile,FILE_READ|FILE_WRITE|FILE_CSV,",");
if(iFile == -1)
return(false);
// write out timestamp and equity to file
sTimestamp = TimeToStr(TimeLocal(),TIME_DATE|TIME_SECONDS);
sEquity = DoubleToStr(AccountEquity(),2);
FileWrite(iFile,sTimestamp,sEquity);
FileFlush(iFile);
// close the file
FileClose(iFile);
// upload the file
// Note: a second param can be used to specify ftp_path
// returns true if successful, false otherwise
return(SendFTP(sFile));
}
Dislikedis there a way to have this update automatically as soon as the market updates?Ignored
The "Test" button sends report about the current account status using the specified settings that allows to check their workability. If it has been tested successfully, the "OK" button must be pressed to activate these settings. If the test did not succeed, it is recommended to check all settings again and retest.