Well the fact is you might not be definite about the specs of the function. The types of the arguments is what am talking about. Are you 100% sure function rtcMsgBox is accepting both arguments of type const void * ?
Basically when you need to load a DLL in vb the dll must be replacing vb strings with BSTR.
The same way I assumet the function you mentioned may be accepting BSTR.
Apart from this there is a tool called specmaker that wine developers created to dump down the specs of functions in windows shared libraries. You cant find its windows version anywhere on web, but I have ported it perfectly to windows NT and it works for me, the reason I am not posting it here is it may be counted a macilius executable, so I will be putting it alongwith an article that I will post at codeguru for dealing with dlls that you dont know.
It's also possible I have to initialize this library, i.e. to call some kind of function other than DllMain (which by the way is called automatically).
1) I do this to understand Windows better, get experience in work with different kind of tools and so on. Also export from dll helps me to understand assembler. I'm not going to write code in assembler, as the process in not effective.
1) Okay, that explains alot, but... I believe, before starting to mess with "different kind of tools" it would be good to get some very basic Windows programming skills and knowlege. Afraid, you try to skip this important phase, though as lots of beginners do.
2) A really happy BSTR pointer must point at string part but not length (see documentation on BSTR). The compile error tells me that you're missing some header file to be included.
I'm coming it at from a low level perspective, but one way is to call the function without arguments and look at the stack pointer on return.
The stack pointer will typically move by the number of bytes expected by the function (if it takes any), but it assumes much, and yuo must be prepared for a few headaches.
Another option is to dig out a debugger, again call without parameters, and examine the function. You might be able to figure out not only how many parameters to pass, but what it does, too.
It's the only way to figure out undocumentd features.
What you basically need to do is disassemble the runtime library, but I think you might be in trouble with MS if you do.
Bookmarks