I want to use datasocket to read the file (txt format) from ftp server.
Whether the URL of DS_open is ftp://10.50.28.43/wen1.txt or
ftp://10.50.28.43/wen1.txt[text], it return the message
"Error: Can't open file to read from. " I'm sure the ftp server is opened.I use the following code to read the data
////
hr = DS_GetDataType (dsHandle, &type, NULL, NULL);
if (type & CAVT_ARRAY) {
hr = DS_GetDataValue (dsHandle, CAVT_FLOAT|CAVT_ARRAY,data,
5000*sizeof(float), &sz, NULL);
}
else {
hr = DS_GetDataValue (dsHandle, CAVT_CSTRING, message, 100, NULL, NULL);
}
////
I wonder if the datatype is right and how to get the value.
Thanks!