Jump to content

A New Cd-switching Utility

Recommended Posts


Hope i not pollute this thread with my question.

Can I use cdswitch to detect my CD/DVD???

In fact I'm using a UA (WinXP+Appz) DVD. When I run it, after the WinXP install and restart, my cdrom is not detected and i got an error: "'Windows No Disk' 'There is no disk in the drive." Although i have this in my wpi.cmd file

for %%i in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do if exist %%i:\WIN51 set CDROM=%%i:
echo Found CD-Rom as drive %CDROM%

When wpi.cmd is called by winnt.sif


If so, what winnt.sif [GuiRunOnce] command do i use



Link to comment
Share on other sites

Hmm, you might want to create a new topic for this. The only help for you from CDswitch would be the log-feature or variable-feature, which detects all drive letters. Otherwise it can't help you.

Link to comment
Share on other sites

  • 2 weeks later...

@ totoymola: well, CDswitch 0.7 itself is basically done with the previous beta, I only have to change some small stuff. I still have to do alot for the parameter generator. The GUI I had in mind is done (which was the most work anyway), now I just have to add tooltips and the checking mechanism I implemented in CDswitch itself to avoid errors.

Basic line is this; when I find some time, I'll continue. But when 0.7 is done, I can finally continue adding some new stuff (as far as it's possible). :P

@akon: dunno why you asked in this topic, but consider it done.

Edited by Nanaki
Link to comment
Share on other sites

0.7 (06-07):

- Slowed down disc-checking a wee bit

- Renamed "/f" to "/g"

- Added "/?" parameter for a small help-overview

- Fixed some critical Silent Mode bugs

- Added parameter generator

First post updated.

Link to comment
Share on other sites

<span style='font-size:9pt;line-height:100%'>

0.7rev1 (07-07):

- Fixed a small log-bug


<span style='font-size:9pt;line-height:100%'>

CDswitch parameter generator 0.1rev1 (07-07):

- Adjusted drive letter fields for use with variables


Both on first page

<span style='font-size:9pt;line-height:100%'>

0.8a (07-07):

- Much better memory usage, CDswitch now uses less

- Slashed size a bit

- General code clean-up and improvements

- Improvements to file navigation for /r

- Speeded up spawning the default image a bit

- Fixed a bug where /r would still be launched with a faulty exit

- Rewritten Silent Mode a bit to be more extensible

- Added /e in Silent Mode as an alternative for /o

- When started with "/s" but other parameters are incorrect, GUI-mode isn't loaded anymore

- Completely rewritten Variables Mode to be more stable, extensible and consistent

- Variables Mode can now use disc variations to detect a drive

- Added /lr to strikethrough a label

- Added /li to italic a label

- Added /lu to underline a label

- Fixed a bug where explicitly calling 0 as a position didn't work with the default image

- Added /b to hide the border

- Added ErrorLevels when CDswitch exits


Let's see. Bug fixes. Most changes goto Variables Mode I guess. The old parameters won't do anymore, they weren't very clear. It now looks like Silent Mode to use.

You call it with "/v", then choose the action, /c (create) or /d (delete). Finally, pick a drive or "ALL". This mode can now use the disc variations to write to a variable. Examples:

Write all drives to %CD1%, %CD2%, ...

cdswitch /v /c ALL

Delete those again

cdswitch /v /d ALL

Create or delete them on a user-level

cdswitch /v /c ALL /u
cdswitch /v /d ALL /u

Write one drive letter to the variable %CDDRIVE%

cdswitch /v /c d:

or for the first drive

cdswitch /v /c 1

or second

cdswitch /v /c 2

or the drive containing the disc with label "Disc_One"

cdswitch /v /c /g:"Disc_One"

Delete it again:

cdswitch /v /d

Both on a user level:

cdswitch /v /c d: /u
cdswitch /v /d /u

Silent Mode also has some changes, but nothing that you'll really notice (unless you want to use a disc with label "/s" in Normal Mode :/)

For Normal Mode, there are some extra font-attributes you can set. "/lr" to strikethrough, "/li" to italic and "/lu" to underline.

Second new parameter is "/b", which -when used- hides the small black border.

cdswitch test 1 /li /lr /lu /b

(to show 'em all at once), spawns this:


One final thing, it was requested by someone in this topic, the %errorlevel% variable is set now depending on how CDswitch exited.

3 -> CDswitch exited normally
4 -> CDswitch exited with an error ("/r" was ignored)
5 -> too few parameters were supplied
6 -> Silent Mode was launched, but with too few parameters
7 -> Silent Mode exited succesfully
8 -> Variables Mode was launched, but with too few parameters
9 -> Variables Mode exited succesfully

<span style='font-size:12pt;line-height:100%'>

Download CDswitch 0.8a here (179k).</span>

I wonder how many people get sick of this topic getting bumped all the time. :P

Edited by Nanaki
Link to comment
Share on other sites

I Installed windowsXP from CDDrive2 and at T-12 min, when the cdswitch utility is to be called to ask for the 2nd CD, it is not executing for the Drive2. I tried reinstaling XP again from the CDDrive1, it is working. Is it not meant to use with CDDrive2. Is this a bug or a feature not yet implemented? I tried with WinXP and Win2003. WinXP identifies CDWriter as Drive1, DVDDrive as Drive2. Win2003 identifies CDDrive as Drive2, DVDDRive as Drive1. Both gave the same problem : CDSwitch cannot use Drive2 for installation (to switch CDs). Pl respond as i find everything else in the utility as satisfying my requirements through the parameters.

Link to comment
Share on other sites

@prathapml: okay, I'll bump it more. :P

@rajesh.kumar: Weird. I'm on a laptop using only one drive so I didn't thoroughly tested it yet. It worked however on my desktop with multiple drives.

edit: what the, since when did this become sticky. Goody :)

edit2: *deleted test-routine* I confirmed the problem. That's a good thing, as it's always better that I can reproduce it. I'll look into it and fix this problem soon. Maybe even today. Sorry for the probs.

edit3: I've fixed it I think.

<span style='font-size:9pt;line-height:100%'>

0.7rev2 (12-07):

- Fixed a bug causing only the first drive to work


You can download it at the first page. :)

I first fixed this bug in the version I was working with, so I'm gonna throw my progress on that one online too:

<span style='font-size:9pt;line-height:100%'>

0.8a2 (12-07):

- Fixed a bug causing only the first drive to work

- General improvements (everybody loves those)

- Added /s parameter to play a sound

- Added /f parameter to detect a drive by file

- Renamed "/w" to "/rw"

- Fixed a bug where /r would ignore %PATH%


Let's see, what's new? "/s" is meant to play a soundfile (MP3/WAV, no OGG or FLAC or so :P) when the GUI-window appears. I'll improve this parameter later anyway.

Next, instead of drive letter, drive number, or "/g" to detect a drive by label, there's also "/f" now. It looks like "/g", but instead of searching to the drive holding a disc with a certain label in it, it looks for the drive holding a disc with a certain file.

It automatically adds the drive letter in front of a path, so if you do this:

cdwitch Disc_One /f:cd.txt

it will look for cd.txt in the root of the disc. so D:\cd.txt.

If you want to look into folders too, it's the same:

cdwitch Disc_One /f:Install\Apps\cd.txt

so, D:\Install\Apps\cd.txt.

One last change is that "/w" has been renamed to "/rw". At least now you can tell it's connected to "/r".

Download CDswitch 0.8a2 here (179k)

Edited by Nanaki
Link to comment
Share on other sites

Thats a wonderful response Nanaki. I would use your new version and be back. Hope it would satisfy. Meanwhile, i used someother utility which also doesnt work. Your response has come in the right time.

Apart from this topic, i just dont know where to search coz i spent 2 days looking for some information on how to change ie6 toolbar background image and the animated logo in the top right corner, during unattended install of xp sp2. i tried IEAK and .ins files. but it didnt work. If anyone know abt it, plzzzz help.

Edited by rajesh.kumar
Link to comment
Share on other sites

I gave this command (V0.8a2) : cdswitch "O2003_CD1" H: /r:"Notepad.exe".

H: is the first drive. Tray keeps ejecting and never goes in fully (even to for check the cd label) when i close it. When I use with the second drive (I:), it takes it. I dont know whether im using it right but i tried several times. It was the same with Version 0.7rev2. Simply i tested in the cmd window.

Edited by rajesh.kumar
Link to comment
Share on other sites

@rajesh.kumar: Have you tried closing it with the CLOSE-button on your drive instead of pushing it shut?


<span style='font-size:9pt;line-height:100%'>

0.8b (15-07):

- Removed error-messageboxes with Silent Mode and Variables Mode

- General improvements (especially to the run- and pic-checking)

- More improvements to memory-usage

- Rewritten parameter-checking

- Added /l:"value"-parameter to override the displayed text

- Added default switches for "/s" and "/k"

- New default image

- Smaller size

- Improved file navigation for "/r" and "/s"


Alrighty then.

First new thing (next to more stability and speed improvements) is "/l:VALUE". You can override the displayed label, so it suits your image more.


cdswitch WinXP_2 D: /l:"Disc two"

This will search for the disc with label WinXP_2, but CDswitch will display "Disc two" on the screen.

Next new feature are the default switches.

You can now just use /s or /k without supplying a value. It well then use a default value.

Example (combined):

cdswitch WinXP_2 D: /k /s

"/k" will create a log at c:\cdswitch.txt and "/s" will play c:\windows\media\chimes.wav". You can still supply alternate values of course.

There's also a new default image:


Feedback on it is always welcome.

Finally, the size has decreased a bit again. It's getting smaller and smaller. :)

Download CDswitch 0.8b (169k) here

No parameter will be changed or added in the final 0.8, so I can now calmly work on CDswitchParameterGenerator 0.2.

And now I'm off [dutchmode]gentsefeesten![/dutchmode]

Edited by Nanaki
Link to comment
Share on other sites

Pff, I'm not gonna work on CDswitch for awhile normally, so I'm finalizing 0.8. Not much is different from 0.8b, as I'm tired, it's hot, I have a headache, and I'm leaving in about an hour anyway.

0.8 (16-07)

- Added .INI-support

- Updated /?

- Updated /k

I'll expand the .INI-support in the next version, so I'm not explaining it right now. :P

The parameter generator has also been updated:

0.2 (16-07):

- General GUI improvements

- Added support for new and adjusted 0.8-parameters

- Now generates cleaner output

- Added better templates for RunOnceEx and XPlode4

And then there's the help-file, also updated and cut down in size.

If you don't like the new default image, you can use the old one, there's an .INI and .JPG in the first post to accomplish that. Just put those in the same folder as CDswitch.

Enjoy. =p

Edited by Nanaki
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.

  • Create New...