Originally posted by: Ovanes Markarian
In the cab sdk another compression type is defined: LZX. The problem I occure is to decompress a cabinett that was compressed with this compression type. The strange thing is that if I use standard cab sdk sample to decompress this cab it works fine if I compiled this sample using the make file provided with the sample. If I create a new VC++ 6 project add there this sample .c file compile it and run, the fdi.lib fails to decompress the cab. The error code returned is:
FDIERROR_BAD_COMPR_TYPE
Unknown compression type in a cabinet folder [Should never happen] A folder in a cabinet has an unknown compression type. This is probably caused by a mismatch between the version of FCI.LIB used to create the cabinet and the FDI.LIB used to read the cabinet
May be someone knows what compiler or linker settings causing this problem
Thanks,
Ovanes
Originally posted by: David
THEN MY PROGRAM WORK, IT DON'T CRASH,
Here is my code :
CCabinetBuilder cb(12345,1440000,1440000,250000);
if (!Bverif1 || !Bverif2)
ALWAYS "ALL IS OK" BUT NEVER CREATE CAB FILE ??????
dlafay@pop.multimania.com
VC6 SP3 compil but I must delete all the following
test in the sources : #ifdef __stdAfx__
then I include stdafx all the time and now it's OK.
BUT HE DO NOTHING NOTHING NOTHING
IT DOESN'T CREATE cab file
the functions return TRUE... I don't understand,
BOOL Bverif1, Bverif2;
CString message;
if(cb.InitCabinet("C:\\Temp","monCab","Disk"))
{
// And now we add the files
Bverif1 = cb.AddFile("D:\\Test\\fichier1.txt");
Bverif2 = cb.AddFile("D:\\Test\\SousRep\\fichier2.txt");
{
message.Format("Could not add file(s)");
MessageBox(message);
} else MessageBox("ALL IS OK");
} else MessageBox("Error in InitCabinet !!!");
Originally posted by: Hallam
How do I add files to an existing cab file.
I know where the pre-exisiting file is but I cannot seem to get CCabinetBuilder to access the cab and then start adding the updated or new files.
Any ideas ?
ReplyOriginally posted by: Chris Maunder
The source code has been updated with Daniel's fix.
Thanks Daniel!
ReplyOriginally posted by: Erievisth
The classes are very usefule in creating cab files and extracting.
But, can I create self-extracting exe files using these classes?
A little explanation with some sample code will be appreciated.
Originally posted by: Pierre Couderc
Thank you for this fine simplification of Cab use for "un-convinced C programmer"!
I think that I missed something when trying to install it under MFC VC6SP1
First, my C6 refuses absolutely that "stdafx.h" be inside an
#ifdef SOMETHING
So I removed your #ifdef STDAFX in all your .CPPs
Then, I get a TRACEX undefined, that I resolved by removing
an #ifdef __MFC___ somewhere in your code
This does not seem very important, but I am surprised to get these problems seeing how your code is well
done, that could mask some bigger problem.
Maybe it is only a joke from C6...
Thank you again
Pierre Couderc TOL.S.A France
Originally posted by: Chris Montgomery
Hello,
Is there a way I could encrypt the files after they have been compressed without encrypting the whole thing in one shot?
Is this possible?
- Chris