>That did it!
>
>The only thing I dont understand is why ALL the values
>need to be passed by ref?
Well, the size value doesn't, but the strings are indicated as being passed by reference. Anytime you see a C declaration with one or more parameters that begin "lp", it indicates that the value is to be passed by reference in VFP. "lp" stands for "Long Pointer". You'll also come across declarations that read something similiar to DWORD lpsize. In this case, it means that from VFP you must pass the integer by reference.
FWIW, I've heard that VFP passes all strings by reference regardless of the declaration. However, even so, you must specifically declare that a string buffer to receive a value is passed by reference. If you don't, it won't work.
George
Ubi caritas et amor, deus ibi est