Login  
Search All Forums
Dart Home | PowerTCP FTP for ActiveX | Custom Development Reply | PowerTCP FTP for ActiveX Topics | Forums   
AuthorForum: PowerTCP FTP for ActiveX
Topic: Retrieve function garbling data in C++
mhfraserEMS
fraser.m@emstechnologies.ca

From: Ottawa, ON Canada
Posts: 4
Member Since: 05/14/03
posted March 26, 2004 1:56 PM

I am using the dartFTP ActiveX to try and download data. If I downloaded it to a local file it downloads correctly, but if I try and download it to memory it gets corrupted.

I am passing the retrieve function a VARIANT of type BSTR and a NULL pointer for the return value. It returns a string result with every other byte being the proper data returned.
However, some of the data bytes are incorrect. Looking at the other bytes in the BSTR (the ones that should all be 0s), the bytes that are different have values in them.
The documentation states that an undimensioned byte array is an option for downloading data, but I can find no examples anywhere of how to do this, or what an undimensioned byte array actually is. I have tried SAFEARRAY as part of the VARIANT, but had no luck as yet.

Thanks for any help you can provide.
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted March 26, 2004 2:14 PM

Using Byte arrays in C++ is pretty advanced. Normally you have to get a support incident or have support with us so that we can write a special sample for you.

Before you go that route, I would search this forum for the words SafeArrayCreate and see if any of the topics you get help. I would also look into the functions MultiByteToWideChar to see if there is anything you can do using that.

If you are still not able to figure it out, please contact us directly to discuss other support options.

Reply | PowerTCP FTP for ActiveX Topics | Forums   
This site is powered by PowerTCP WebServer Tool PowerTCP WebServer for ActiveX