Some way to call CreateThread api?
You are passing a double
double hThread = CreateThread(0, 0, myMessageBox(), 0, 0, 0); // ^^^^^^^^^^^^^^ this is a function call. double uninitializedDouble = myMessageBox(); double hThread = CreateThread(0, 0, uninitializedDouble, 0, 0, 0); // Same as.If you want to pass a function pointer you'd need to use
double hThread = CreateThread(0, 0, myMessageBox, 0, 0, 0); // ^^^^^^^^^^^^ pointer to a function.Except MT4 does NOT HAVE POINTERS so it will not compile!
You are not compiling "with a function," you are compiling using the the return value FROM a function.
There is no problem, except that you are hard of reading. You answered your own question 1) "I think is not possible without a dll." and 2) I confirmed it. What part of "MT4 does NOT HAVE POINTERS" was unclear?
I tried with this:
But I can´t create a new thread, I think is not possible without a dll.
myMessaBox is called from the current thread from myMessageBox() not from CreateThread