I am using TestStand 3.5 and LabWindows/CVI 8. The prototypes for my functions callled from TestStand look like this:
"void __declspec(dllexport) __stdcall myFunc (short *errorOccurred, long *errorCode, char errorMsg[1024])"
It is nice to be able to pass errorMsg as a fixed size array, as opposed to just a pointer, so the burden or allocating/deallocating memory is removed from me. The size of the buffer (1024) is defined in the sequence editor and I can generate the prototype and code for my function, but it seems that the two are somewhat seperate. By that I mean that I can change the literal number in either place and get them not to agree (accidently).
It would be nice if could specify the 1024 buffer size in the TestStand sequence editor (as I am doing now), and then have this buffer and the buffer size passed down to my function. So, I'd like to have my function read "... char errorMsg[], int errorMsgBuflen ... ". Or , alternatively, is there some property/function call that I can make to get the size of the errorMsg Buffer?
While I have your "ears", is there anything magical about 1024 for the buffer size? That seems to be the number I've seen used in all of the examples.
Thanks
Don Frevele