Forum posts for extrac32.exe

Extracting .cab files

I want to extract all .cab files inside a particular folder in c# .net

static int ExtractCabFiles()
{



try
{

Console.WriteLine('Extracting Cab files');
string strCommand = @'extrac32.exe';
var strArrCabDetails = new string[3];
strArrCabDetails[0] = ConfigurationManager.AppSettings['Cab_Files_Path'];
strArrCabDetails[1] = '/L';
strArrCabDetails[2] = ConfigurationManager.AppSettings['Event_Files_Folder_Path'];

WriteLog('Cab files path : ' + ConfigurationManager.AppSettings['Cab_Files_Path'] + '', false, false);

const string strArgsSeparator = ' ';
string strArgs = string.Join(strArgsSeparator, strArrCabDetails);

Process process = new Process();
process.StartInfo.FileName = strCommand;
process.StartInfo.Arguments = strArgs;
process.StartInfo.CreateNoWindow = true;
process.StartInfo.UseShellExecute = false;
process.StartInfo.RedirectStandardError = true;
process.StartInfo.RedirectStandardOutput = true;
WriteLog('Extract Command : ' + strCommand + ' ' + strArgs + '', false, false);
process.Start();

//string strError = process.StandardError.ReadLine();
iExitCode = process.ExitCode;


}
catch (Exception ex)
{

}
}


This code will extract a single .cab file but I want to extract multiple .cab files from the folder.

View complete forum thread with replies

Other posts related to extrac32.exe

See Related Forum Messages: Follow the Links Below to View Complete Thread

Extracting .cab files

What is the carbon footprint of your coffee?

Is it low? Is it high? Can this things really kill the planet Earth? Maybe the answer will surprise you. Maybe not.