Skip to content
View in the app

A better way to browse. Learn more.

MSFN

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

setting cd-rom drive varible

Featured Replies

IF EXIST D:\AUTORUN.INF set CDROM=D:
IF EXIST E:\AUTORUN.INF set CDROM=E:
IF EXIST F:\AUTORUN.INF set CDROM=F:
IF EXIST G:\AUTORUN.INF set CDROM=G:
IF EXIST H:\AUTORUN.INF set CDROM=H:
IF EXIST I:\AUTORUN.INF set CDROM=I:
IF EXIST J:\AUTORUN.INF set CDROM=J:
IF EXIST K:\AUTORUN.INF set CDROM=K:
IF EXIST L:\AUTORUN.INF set CDROM=L:
IF EXIST M:\AUTORUN.INF set CDROM=M:
IF EXIST N:\AUTORUN.INF set CDROM=N:
%CDROM%
pause

1) If you run this batch with your original commands with a cdrom in a drive, it works.

2) You do not use the cdrom variable within your script.

So no problem showing with the script shown, that I can see. Why set the cdrom variable? Not needed.


  • Author

well by what i think i did a test run the cdrom varible carried over to wpi and i need the cdrom varible so i dont have to make setup copy over 1.6 gigs to the hdd

The CDROM variable is is limited to within the script. It will not be available for use by WPI as set by this script. WPI needs a routine within itself for setting a CDROM variable.

  • Author

well then how do i set the varible to be also in WPI

Here is a link in the WPI forum for find CDROM

  • Author

well thankyou very much this will be helpful but one thing i have left to ask is if i open a cmd batch file from wpi will the cdrom varible still work or will i ahve to modify all these cmds somehow

BTW in WPI if i have a 2nd cmd setup does that wait for the first one to finish

If you create a cmd batch file from WPI that will access the CDROM, you will need to set a CDROM variable within that script.

Consider the CDROM variable as only a local variable.

Use Start /Wait for programs in command files to stop following being executed.

  • Author

Well i have numerous scripts like this to run the setups and kill processes or add regkeys after the setup

@echo off
title Installing MSN Messenger Plus

start /wait %cdrom%\install\Applications\msnplus\6\MsgPlus-325.exe /SilentInstallNoSponsor
%cdrom%\install\Applications\msnplus\pskill.exe msnmsgr.exe
%cdrom%\install\Applications\msnplus\pskill.exe msgplus.exe
exit

how would i make this into a full WPI script thing

I am not really familar with WPI commands. It would be best to use the WPI commands. Otherwise, each of those scripts would need a cdrom set routine.

e.g.

@echo off
title Installing MSN Messenger Plus

IF EXIST D:\AUTORUN.INF set CDROM=D:
IF EXIST E:\AUTORUN.INF set CDROM=E:
IF EXIST F:\AUTORUN.INF set CDROM=F:
IF EXIST G:\AUTORUN.INF set CDROM=G:
IF EXIST H:\AUTORUN.INF set CDROM=H:
IF EXIST I:\AUTORUN.INF set CDROM=I:
IF EXIST J:\AUTORUN.INF set CDROM=J:
IF EXIST K:\AUTORUN.INF set CDROM=K:
IF EXIST L:\AUTORUN.INF set CDROM=L:
IF EXIST M:\AUTORUN.INF set CDROM=M:
IF EXIST N:\AUTORUN.INF set CDROM=N:

start /wait %cdrom%\install\Applications\msnplus\6\MsgPlus-325.exe /SilentInstallNoSponsor
%cdrom%\install\Applications\msnplus\pskill.exe msnmsgr.exe
%cdrom%\install\Applications\msnplus\pskill.exe msgplus.exe
exit

A lot of copy and pasting into all script needed.

@echo off
title Installing MSN Messenger Plus
for %%a 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 %%a:\Autorun.inf set CDROM=%%a:
start /wait %cdrom%\install\Applications\msnplus\6\MsgPlus-325.exe /SilentInstallNoSponsor
%cdrom%\install\Applications\msnplus\pskill.exe msnmsgr.exe
%cdrom%\install\Applications\msnplus\pskill.exe msgplus.exe
exit

This style looks better though

Edit: If your software is on the cd in install\Applications... , why not have these batch files in install\Applications, and use relative addressing?

WPI will have the cdrom variable so you just call the batches on the cd.

  • Author

if anyone knows WPI could they help me here

@MHz ; yeh that looks better but still brings up errors, thanks for all the help tho

Hey un4given1 ;)

I don't mean to gloat, but yes, I do see that both of us try to help people, and ask them to search when its relevant!

(pun intended...  I'm referring to what you'd said about too many people responding with "search" instead of the answer)

I did that on purpose ;)

  • Author

will the commands that i use in cmd prompt work in WPI like

COPY

REGEDIT /S

start /wait

Here A script That Will Run From Any Where And Pass The Varibles

The Only Down side it seems is it cant handle spaces in the names

I tried quotes but was not able to get it to work with spaces.

So make Sure There no Space In The script.

Purple That A Test Of A Install I Did With This EDIT TO YOUR NEEDS

Red Means You Can delete

Orange Is The Test Of The Cmd

Blue Is the Clean Up Part

echo off

cls

mode con: cols=55 lines=4

color 5f

TITLE PSP 9 PRO INSTALL

SET L1=%~dp0TESTLOC1\

MKDIR "%L1%"

ECHO TEST LOCATION 001 > %L1%TSTLOC1.TXT

ECHO MESSAGE TEST 1 >> %L1%TSTLOC1.TXT

ping -n 1 127.0.0.1>nul

goto WORK

:WORK

if EXIST  "%~dp0\TESTLOC1\TSTLOC1.TXT" (SET CD=%~dp0TESTLOC1\)

::::::::::::::::::::::::::::EDIT THIS BELOW AND IT WILL RUN THE INSTALL

::" )echo off

::" )cls

::" )mode con: cols=55 lines=4

::" )color 5f

::" )TITLE MicroAngelo57 INSTALL

::" )SET CD=%~dp0MicroAngelo\

::" )if EXIST  "%~dp0\Install\MicroAngelo\MicroAngelo57.exe" (SET CD=%~dp0Install)

::" )

::  start %CD%\MicroAngelo\MicroAngelo57.exe /S /QN)

::" )

::ping -n 1 127.0.0.1>nul

::SET CD1=%CD%\MicroAngelo\

::ECHO YOUR LOCATION IS:

::SET /P = %CD1%

::::::::::::::::::::::::::::EDIT THIS ABOVE AND IT WILL RUN THE INSTALL

ECHO YOUR LOCATION IS:

SET /P = %cd%

> CU1.vbs echo Dim Garbage

>> CU1.vbs echo set Garbage = (CreateObject("Scripting.FileSystemObject"))

>> CU1.vbs echo msgbox "Starting Clean UP?",vbokonly+48,"Clean Up"

>> CU1.vbs echo Garbage.Deletefile ("%cd%TSTLOC1.TXT")

>> CU1.vbs echo Garbage.DeleteFile ("\CU1.vbs")

>> CU1.vbs echo wscript.sleep 500

>> CU1.vbs echo Delete=("%cd%TSTLOC1.TXT")

>> CU1.vbs echo Delete=("\CU1.vbs")

>> CU1.vbs echo wscript.sleep 500

>> CU1.vbs echo msgbox "Clean UP Completed?",vbokonly+48,"Clean Up Those Files"

start /w CU1.vbs

rmdir %cd%

set /p = Press Key To Close

I made This A self Extracting Rar To Be able To Run From The Link

The Cmd Will Be Located In %systemdrive%

Edited by gunsmokingman

  • Author

how does this script find what the cd drive is becuse im very dumb when it comes to codes

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.