parameter conversion not allowed

 

How can I solve this error I get when I try to compilte my code containing:

the error is for this line:  (error says: parameter conversion not allowed)

int handle = FindWindowA(i, log);
int FindIfDirOpened() {
    string log = "logs";
    string i;
    
    int handle = FindWindowA(i, log);

    return(handle);
}
 
You are importing the windows-function in a different way (its parameters) you use it.
 
And FindWindowA probably takes an ASCII string, not a MT4 Unicode string.
 

I found this indicator in one of the trading forums, but it is still gives a Parameter conversion not allowed.

Can some one fix it please. Your help is appreciated 

Files:
zup_v83fixed.mq4  362 kb
 
erkan_iii:

I found this indicator in one of the trading forums, but it is still gives a Parameter conversion not allowed.

Can some one fix it please. Your help is appreciated

That is very old code. You should learn to use the Search function: https://www.mql5.com/en/forum/150058

Also read: https://www.mql5.com/en/articles/1468

Reason: