# Extract CAB File With A Double Click



## Deke40 (Jun 27, 2002)

This tip comes from one of our members-Starwaves77 in this thread. I just tried it and it works great.

Here's a little batch file to locate & extract any cab file you need.

Open up a new Notepad document and copy and paste these commands into it, just RIGHT click anywhere on the desktop and select NEW, then TEXT ...paste the following into it, , it assumes your CAB folders path is 'C:\windows\options\cabs' ..... change that pathe as needed on line 7, depending on your windows version,

@echo off
md c:\windows\desktop\CabXtrac
if "%1"=="" goto error
CLS
c:
cd c:\windows\desktop\CabXtrac
for %%i in (C:\windows\options\cabs\*.CAB) do extract %%i %1
ECHO.
IF EXIST %1 ECHO %1 successfully extracted.
IF NOT EXIST %1 ECHO %1 not found
goto end
:error
echo.
echo Syntax: CabX file-to-extract
echo Example: CabX Control.exe
echo.
:end

Now --- Save the file as Cab77.bat in your C:\Windows directory. Make sure you type in the .bat extension, (you can name it anything it doesn't have to be cab77)

Now click on Start / Run / C:\windows

Create a shortcut to cab77.bat by right clicking it in the Windows folder and dragging it to your Desktop and choose "New Shortcut Here",

Right click the new desktop shortcut and select Properties, Click the Program tab.

On the line Cmd. line: you will see C:\Windows\cab77.bat

Go to the end of that command, skip a space using your space bar and type in a ? mark so it looks like this:

C:\Windows\cab77.bat ?
Click Apply, then Ok,

Your desktop shortcut batch file will search, find & instantly extract any file you type in it from your CAB folders, you'll never have to use System File Checker, if it cannot find it, it's not there,

You can rename your shortcut to whatever you like just don't change the .bat extension,

Any files you extract using this will go to the desktop folder called CabXtrac on your desktop. (CabXtrac can be named anything you like)

Once your in that folder you can copy those extracted files to where ever they are needed,

The pathe in this batch file is C:\WINDOWS\OPTIONS\CABS,

NOTE:
FOR OTHER COMPUTERS:
Substitute the path to your CAB files in this line for %%i in (C:\windows\options\cabs\*.CAB) do extract %%i %1

your path may be C:\windows\install\cabs, or it may be C:\win98\cabs, search for your cab folder and check it's path to determine that,

If you want to know the exact CAB file that the extraction occurred in, extract the file a 'second' time that will force the search to stop at the cab's location and ask if you want to 'overwrite' ... that's the cab,

So you spend a little time setting it up but after that it's a laser light show ....


----------



## aarhus2004 (Jan 10, 2004)

Hello Deke,

I did that. Got a small window asking for 'parameters' Got stuck with that!
Everything I entered was not valid not found or whatever. What is a 'parameter'? Could you give an example of one for WinMe? Please.

BTW I used this line at seven C:\windows\options\install\cabs\*CAB) and if the parameter 'window' opened would that signify I was on the right path?


----------



## Deke40 (Jun 27, 2002)

Parameter would be what you were searching for.

I used the example of notepad.exe in the parameter window and then shoud end up with the image below. Just close it out and look in your ExtractCab folder and it shoud be there if it is successful.


----------



## aarhus2004 (Jan 10, 2004)

Thanks Deke, I will have another run at it.


----------

