User (Old forums)MemberMay 24, 2013 at 7:47 amPost count: 23064
I am trying out compression of Strings using Xceed ZIP library. Though, I can create ZIP files, I am unable to use Memory Compression. The code I am using is as follows :
?o.Compress(“abhay is a fool”,@ac,.t.)
The call to compress returns 0 and the value of ac remains Blank.
Any help will be appreciated
Thanks in advance.
Imported from legacy forums. Posted by Abh (had 1086 views)Diane [Xceed]ModeratorMay 24, 2013 at 12:24 pmPost count: 1353
We do not officially support FoxPro, and as such cannot provide a direct code sample.
However, the Compress() method takes a ‘Variant’ object as input and writes the compressed data to another ‘Variant’ object.
Since FoxPro supports COM object, it should support COM’s Variant data type.
Create a Variant object and assign your string to it following the guidelines of FoxPro.
For the compressed data, create an empty Variant object (not a null pointer, but a Variant object that isn’t assigned any data) and pass it to Compress() as the second parameter. The function should fill the Variant with compressed data.
Be aware that the compressed data Variant will contain a byte array and not a string.
Imported from legacy forums. Posted by Diane [Xceed] (had 230 views)User (Old forums)MemberMay 25, 2013 at 5:52 amPost count: 23064
No Not working. Am still scratching my head.
Imported from legacy forums. Posted by Abh (had 168 views)User (Old forums)MemberMay 25, 2013 at 6:46 amPost count: 23064
Interestingly, the Object returns 0, that is , “Operation Completed Successfuly”, when I run it. But the FoxPro cCompData variable stays empty.
LOCAL oComp As XceedSoftware.XceedCompression
oComp.CompressionLevel= 9 && xclHigh
oComp.CompressionMethod= 8 && xcmDeflated
cData = “Abhay is a fool”
*LOCAL cCompData As Variant
?”Compressed Data : ” , m.cCompData
Imported from legacy forums. Posted by Abh (had 226 views)Diane [Xceed]ModeratorMay 28, 2013 at 12:10 pmPost count: 1353
Unfortunately, as previously mentioned, we do not officially support FoxPro, and so we aren’t able to help you further at this point. We apologize for the inconvenience.
If you are able to reproduce the issue in small stand-alone test project in VB6, VB.NET or C#, then please send it to us (firstname.lastname@example.org) and we will be able to give it another look.
Imported from legacy forums. Posted by Diane [Xceed] (had 1293 views)
- You must be logged in to reply to this topic.