How can I send binary data in Visual Fox Pro?

How can I send binary data in Visual Fox Pro?

Date Entered: 6/17/2004    Last Updated: 6/17/2004

Foxpro automatically converts strings to byte arrays (UTF8) when marshalling data between the application and an OLE server. This also occurs when using the DataToSendB property of IPWorks. IPWorks expects the data as a Byte Array UTF1. In Foxpro this is done as follows:
cString = chr(0)+chr(0)+chr(4)+chr(183)

oIPWorks.DataToSendB = ConvertBinary(cString)
The ConvertBinary() function converts the string to a UTF1 ByteArray.

We appreciate your feedback.  If you have any questions, comments, or suggestions about this entry please contact our support team at kb@nsoftware.com.