"GetWFile.BAT". Batch file by Benny Pedersen,
PS. Ad-aware (Anti Spy Ware):
If "Ws2_32.dll" and "ws2help.dll" was in Win95 (is not), then
aaw6181.exe would like to install. Hmmm, I didn't knew if they
could be found in a CAB file so I found them on Google.dk :-).
Benny
@echo off
:: Batch file for extracting file(s) from
:: the Cabinet (CAB files on OS CDROM's).
::
:: Tested: Win95, Win95A, Win95B_USB, 95plus, Win98, Win98SE, Plus!98,
:: Win2kProf, WinMe, WinNT4.0(SP5), WinXP Home and WinXP Prof.
:: I tested in a real DOS session (boot floppy, Win95) but most of the
:: testing was done in GUI, WinXP...
::
:: --------------- Config:
:: -- CDROM Drive letter and colon (
,
Set SourceDrive=D:
:: -- File that you want to extract, F,
Set F=Ws2_32.dll
:: -- Use switch /E to extract the file F, or /D just to display,
Set R1=extract.exe /E
:: If using the switch /E, the file F would be extracted into the same
:: folder as %0 (into the current folder of this batch file).
:: -------- End of config.
set R2=%R1% /a
if exist %sourcedrive%\docs.\nul goto:WinXP
if exist %sourcedrive%\win95\nul goto:Win95
if exist %sourcedrive%\win98\nul goto:Win98
if exist %sourcedrive%\win9x\nul goto:WinMe
if exist %sourcedrive%\plus98\nul goto:Plus!98
if exist %sourcedrive%\drvlib\nul goto:WinNT40
if exist %sourcedrive%\bootdisk\nul goto:Win2000
goto:end
Number of cabinet files:
Win95: 19
Win95A: 20
Win95B: 29
Win95B(Plus): 36
Win98: 161
Plus!98: 1 (Companion CD for Windows 98)
Win2000 Prof: 25 [Not 36 *]. [See notes EX.**]
Win98SE: 91 [Not 94 *]. **
WinMe: 28 [Not 33 *]. **
WinNT4.0(SP5): 225
WinXP Home: 33
WinXP Prof: 36
1;[* Not all files with extension CAB is a cabinet file].
2;[**EX.:
Microsoft (R) Diamond Extraction
Tool - Version (16) 1.00.0602 (07/14/97),
ERROR: d:\VALUEADD\3RDPARTY\LEVEL8\MQC.QUE\DATA1.CAB is not a
cabinet file (CAB file on CDROM for OS install Win2k).
ERROR: d:\drivers\cpu\intel\_sys1.cab is not a cabinet file
(CAB file on CDROM for OS install Windows 98SE).
ERROR: d:\add-ons\tsclient\icaclnt\ica32\data1.cab (WinMe).
]
3;[Note: Some of my source OS CDROM's is danish language versions].
:Win98 and Win98SE
set L=%sourcedrive%\add-ons\pws
for %%1 in (msmqocm fp30ext ) do %R1% %L%\%%1.cab %F%
for %%1 in (iis4_01 mts1 ado ) do %R2% %L%\%%1.cab %F%
set L=%sourcedrive%\win98
for %%1 in (catalog3 precopy1) do %R2% %L%\%%1.cab %F%
for %%1 in (mini chl99 ) do %R1% %L%\%%1.cab %F%
if exist %sourcedrive%\drivers\cpu\nul goto:end
::Win98,
set L=%L%\channels\chl
for %%1 in (da_dk de_at de_ch de_de ) do %R1% %L%%%1.cab %F%
for %%1 in (fi_fi fr_be fr_ch fr_fr hi_in) do %R1% %L%%%1.cab %F%
for %%1 in (hr_hr hu_hu in_id it_it ja_jp) do %R1% %L%%%1.cab %F%
for %%1 in (ko_kr ml_my nl_be nl_nl no_no) do %R1% %L%%%1.cab %F%
for %%1 in (pl_pl pt_br pt_pt ru_ru sl_si) do %R1% %L%%%1.cab %F%
for %%1 in (sv_se th_th tr_tr zh_cn zh_hk) do %R1% %L%%%1.cab %F%
for %%1 in (zh_sg zh_tw 99 cs_cz el_gr) do %R1% %L%%%1.cab %F%
for %%1 in (au bb bz ca gy ie jm me ) do %R1% %L%en_%%1.cab %F%
for %%1 in (nz ph sr tt uk us za ) do %R1% %L%en_%%1.cab %F%
for %%1 in (ar cl co cr do es gt hn ) do %R1% %L%es_%%1.cab %F%
for %%1 in (mx ni pa pe pr sv uy ve ) do %R1% %L%es_%%1.cab %F%
set L=%sourcedrive%\cdsample
%R1% %L%\demos\rarc\arcade1.cab %F%
for %%1 in (1 2 3 4 5 6) do %R1% %L%\demos\pitrial.cd\%%1.cab %F%
goto:end
:Plus!98 (Companion CD for Windows 98)
%R1% %SourceDrive%\plus98\plus98.cab %F%
goto:end
:WinMe
%R1% %SourceDrive%\win9x\PRECOPY1.CAB %F%
%R1% %SourceDrive%\win9x\mini.cab %F%
%R2% %SourceDrive%\win9x\BASE2.CAB %F%
set L=%SourceDrive%\drivers\Modem\IBM
for %%1 in (manager win winsys winsys32) do %R1% %L%\Disk1\%%1.cab %F%
%R1% %L%\Disk2\modem.cab %F%
goto:end
:WinNT40 (SP5)
%R1% %sourcedrive%\mssce\alpha\mssce.cab %F%
%R1% %sourcedrive%\mssce\i386.\mssce.cab %F%
%R1% %sourcedrive%\alpha\xenroll.cab %F%
%R1% %sourcedrive%\i386.\xenroll.cab %F%
set L=%sourcedrive%\msie401\alpha
for %%1 in (actsetup axaa branding ) do %R1% %L%\%%1.cab %F%
for %%1 in (mswltalp dxddex fontcore fontsup) do %R1% %L%\%%1.cab %F%
for %%1 in (icwnt javalpha mailnews mplayer2) do %R1% %L%\%%1.cab %F%
for %%1 in (nm21ax sasetup setupaxp wpie4axp) do %R1% %L%\%%1.cab %F%
for %%1 in (ak4 ak4cif java 40cif ) do %R1% %L%\ie%%1.cab %F%
for %%1 in (ax_s1 ax_s2 ax_s3 ax_s4 ax_s5) do %R1% %L%\ie4%%1.cab %F%
for %%1 in (ax_s6 datax mfc40 shlnt sound) do %R1% %L%\ie4%%1.cab %F%
for %%1 in (99 cs_cz da_dk de_at de_ch ) do %R1% %L%\chl%%1.cab %F%
for %%1 in (de_de el_gr fi_fi fr_be fr_ch) do %R1% %L%\chl%%1.cab %F%
for %%1 in (fr_fr hi_in hr_hr hu_hu in_id) do %R1% %L%\chl%%1.cab %F%
for %%1 in (it_it ja_jp ko_kr ml_my nl_be) do %R1% %L%\chl%%1.cab %F%
for %%1 in (nl_nl no_no pl_pl pt_br pt_pt) do %R1% %L%\chl%%1.cab %F%
for %%1 in (ru_ru sl_si sv_se th_th tr_tr) do %R1% %L%\chl%%1.cab %F%
for %%1 in (zh_cn zh_hk zh_sg zh_tw en_au) do %R1% %L%\chl%%1.cab %F%
for %%1 in (ja ko pe zhc zht ) do %R1% %L%\ielpk%%1.cab %F%
for %%1 in (bb bz ca gy ie jm me ) do %R1% %L%\chlen_%%1.cab %F%
for %%1 in (nz ph sr tt uk us za ) do %R1% %L%\chlen_%%1.cab %F%
for %%1 in (ar cl co cr do es gt hn ) do %R1% %L%\chles_%%1.cab %F%
for %%1 in (mx ni pa pe pr sv uy ve ) do %R1% %L%\chles_%%1.cab %F%
set L=%sourcedrive%\msie401\i386
for %%1 in (actsetup axa branding swflash ) do %R1% %L%\%%1.cab %F%
for %%1 in (mswallet dxddex fontcore fontsup) do %R1% %L%\%%1.cab %F%
for %%1 in (icwnt javi386 mailnews mplayer2 ) do %R1% %L%\%%1.cab %F%
for %%1 in (nm21 sasetup setupw95 wpie4x86 ) do %R1% %L%\%%1.cab %F%
for %%1 in (icw95 ir50_32 vdolive pncodec ) do %R1% %L%\%%1.cab %F%
for %%1 in (setupnt fpesetup dxmini pnfilter) do %R1% %L%\%%1.cab %F%
for %%1 in (ailupd schat21 svbvm50 smus_1 ) do %R1% %L%\m%%1.cab %F%
for %%1 in (ak4 ak4cif ak4opt java 4shl95 ) do %R1% %L%\ie%%1.cab %F%
for %%1 in (0cif data mfc40 sound shlnt ) do %R1% %L%\ie4%%1.cab %F%
for %%1 in (ko pe zhc zht ja ) do %R1% %L%\ielpk%%1.cab %F%
for %%1 in (1 2 3 4 5 6 ) do %R1% %L%\ie4_s%%1.cab %F%
for %%1 in (1 2 3 4 5 ) do %R1% %L%\ie4nt_s%%1.cab %F%
%R2% %L%\msgms_1.cab %F%
set L=%L%\chl
for %%1 in (cs_cz da_dk de_at de_ch de_de ) do %R1% %L%%%1.cab %F%
for %%1 in (el_gr en_au en_bb en_bz en_ca ) do %R1% %L%%%1.cab %F%
for %%1 in (en_gy en_ie en_jm en_me en_nz ) do %R1% %L%%%1.cab %F%
for %%1 in (en_ph en_sr en_tt en_uk en_us ) do %R1% %L%%%1.cab %F%
for %%1 in (en_za es_ar es_cl es_co es_cr ) do %R1% %L%%%1.cab %F%
for %%1 in (es_do es_es es_gt es_hn es_mx ) do %R1% %L%%%1.cab %F%
for %%1 in (es_ni es_pa es_pe es_pr es_sv ) do %R1% %L%%%1.cab %F%
for %%1 in (es_uy es_ve fi_fi fr_be fr_ch ) do %R1% %L%%%1.cab %F%
for %%1 in (fr_fr hi_in hr_hr hu_hu in_id ) do %R1% %L%%%1.cab %F%
for %%1 in (it_it ja_jp ko_kr ml_my nl_be ) do %R1% %L%%%1.cab %F%
for %%1 in (nl_nl no_no pl_pl pt_br pt_pt ) do %R1% %L%%%1.cab %F%
for %%1 in (ru_ru sl_si sv_se th_th tr_tr ) do %R1% %L%%%1.cab %F%
for %%1 in (zh_cn zh_hk zh_sg zh_tw 99 ) do %R1% %L%%%1.cab %F%
goto:end
:Win2000 Professionel
set L=%sourcedrive%\i386
%R1% %sourcedrive%\valueadd\3rdparty\security\sdti\acec lnt.cab %F%
%R2% %L%\iis5_01.cab %F%
for %%1 in (dajava driver fp40ext manager) do %R1% %L%\%%1.cab %F%
for %%1 in (ims iisdbg winsys32 modem osc) do %R1% %L%\%%1.cab %F%
for %%1 in (win winsys xmldso ) do %R1% %L%\%%1.cab %F%
set L=%L%\win9xmig\mapi
for %%1 in (80 802 803 98omi ) do %R1% %L%\%%1\%%1.cab %F%
for %%1 in (98mapi\98map ex40a\40a ) do %R1% %L%\%%1.cab %F%
%R1% %L%\ex50sp2\50sp2.cab %F%
%R1% %sourcedrive%\support\tools\deploy.cab %F%
%R1% %sourcedrive%\support\tools\support.cab %F%
goto:end
:WinXP Home and WinXP Professionel
set L=%sourcedrive%\I386
for %%1 in (DRIVER FP40EXT IMS MANAGER MODEM) do %R1% %L%\%%1.cab %F%
for %%1 in (MMSSETUP OSC WIN WINSYS WINSYS32) do %R1% %L%\%%1.cab %F%
if not exist %sourcedrive%\dotnetfx\nul goTo XP both
::Professionel,
for %%1 in (HSCXPSP1 IIS6 SP1) do %R1% %L%\%%1.CAB %F%
:XP both
set L=%L%\WIN9XMIG\MAPI
for %%1 in (80 801 802 803 98OMI) do %R1% %L%\%%1\%%1.CAB %F%
%R1% %L%\98MAPI\98MAP.CAB %F%
%R1% %L%\EX40\40.CAB %F%
%R1% %L%\EX40A\40A.CAB %F%
%R1% %L%\EX40SP3\40SP3.CAB %F%
%R1% %L%\EX40SP4\40SP4.CAB %F%
%R1% %L%\EX50SP1\50SP1.CAB %F%
%R1% %L%\EX50SP2\50SP2.CAB %F%
%R1% %L%\98MAPI\98MAPDAN.CAB %F%
%R1% %L%\98OMI\98OMIDAN.CAB %F%
%R1% %L%\80\80DAN.CAB %F%
%R1% %L%\802\802DAN.CAB %F%
%R1% %L%\803\803DAN.CAB %F%
%R1% %L%\EX40A\40ADAN.CAB %F%
%R1% %L%\EX50SP1\50SP1DAN.CAB %F%
set L=%sourcedrive%\SUPPORT\TOOLS
for %%1 in (DEPLOY SUPPORT SUP_PRO SUP_SRV) do %R1% %L%\%%1.cab %F%
goto:end
:Win95 and Win95A and Win95B and Win95B(Plus)
%R2% %sourcedrive%\win95\win95_02.cab %F%
%R2% %sourcedrive%\win95\precopy1.cab %F%
%R1% %sourcedrive%\win95\mini.cab %F%
if not exist %sourcedrive%\demos.\nul goto:end
::Win95B and Win95B(Plus),
%R1% %sourcedrive%\demos\pacman\arcade1.cab %F%
if not exist %sourcedrive%\plus\nul goto:end
::Win95B(Plus),
%R2% %sourcedrive%\plus\plus_1.cab %F%
goto:end
:end
pause
cls
set SourceDrive=%nothing%
set R1=%nothing%
set R2=%nothing%
set L=%nothing%
set F=%nothing%
:: Batch file by Benny Pedersen,
:: http://2dos.homepage.dk
:: (not uploaded, Feb 21, 2004).
:EOF