:) Hi
I'm having this MT4 indicator, which i didn't use for a long time, back then it was working perfectly well but now it's not loading and while compiling it's shows a warning "possible loss of data due to type conversion" for this code.
The developer who made this indicator for me has left providing services here in this site, can someone please help me to make this indicator usable
Above coding is part of this below section
Thanking you in advance for all your efforts to help me :)
if(Selected) { SymbolsNumber = (FileSize(hFile) - 4) / 128; Offset = 116; } else { SymbolsNumber = FileSize(hFile) / 1936; Offset = 1924; }try to change FilleSize(hfile) to any number, let's say 2000 and do the math..will it guarantee integer number return?
double tsymbolnumber = 0.0; if(Selected) { tsymbolnumber = (FileSize(hFile) - 4) / 128; Offset = 116; } else { tsymbolnumber = FileSize(hFile) / 1936; Offset = 1924; } SymbolsNumber = int(MathCeil(NormalizeDouble(tsymbolnumber,1))); if (SymbolsNumber<1) { FileClose(hFile); return(-1); } else { ArrayResize(Symbols, SymbolsNumber); // read symbols from file if(Selected) FileSeek(hFile, 4, SEEK_SET); for(int i = 0; i < SymbolsNumber; i++) { Symbols[i] = FileReadString(hFile, 12); FileSeek(hFile, Offset, SEEK_CUR); } FileClose(hFile); // return count of symbols return(SymbolsNumber); }
my best guess..i could be wrong
try to change FilleSize(hfile) to any number, let's say 2000 and do the math..will it guarantee integer number return?
my best guess..i could be wrong
I tried as suggested by you, but any of it didn't worked
I tried as suggested by you, but any of it didn't worked
if(Selected) { SymbolsNumber = (int)(FileSize(hFile) - 4) / 128; Offset = 116; } else { SymbolsNumber = (int)FileSize(hFile) / 1936; Offset = 1924; }
:D it worked, compilation successful. Thanks a lot
Now last thing that it's not attaching to a chart i.e. showing an error "Expert 'HSTconverter' is not custom indicator and will be removed"
Haryani H:
Now last thing that it's not attaching to a chart i.e. showing an error "Expert 'HSTconverter' is not custom indicator and will be removed"
Nobody knows anything about that problem from the content of this thread.
Nobody knows anything about that problem from the content of this thread.
can I dm you my indicator source file, so that you could have a look at it for the problem?
can I dm you my indicator source file, so that you could have a look at it for the problem?
No, I do not accept direct requests.
No, I do not accept direct requests.
ok, thanks for all your help :)
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
:) Hi
I'm having this MT4 indicator, which i didn't use for a long time, back then it was working perfectly well but now it's not loading and while compiling it's shows a warning "possible loss of data due to type conversion" for this code.
The developer who made this indicator for me has left providing services here in this site, can someone please help me to make this indicator usable
Above coding is part of this below section
Thanking you in advance for all your efforts to help me :)