MSFN Forum: chose script - MSFN Forum

Jump to content


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

chose script Rate Topic: -----

#1 User is offline   MitsuMan 

  • Member
  • PipPip
  • Group: Members
  • Posts: 146
  • Joined: 12-March 06

Posted 25 September 2012 - 11:05 AM

Hello

i have a question. is it possible to make a .bat file with commands. where use can chose to run a program...

example

Please chose with one

1 Program1.exe
2 Program2.exe

then when user press 1 the first install or if they press 2 the number 2 install..

Can anone help me with that...


#2 User is offline   gunsmokingman 

  • MSFN Master
  • Group: Super Moderator
  • Posts: 2,352
  • Joined: 02-August 03
  • OS:none specified
  • Country: Country Flag

Posted 25 September 2012 - 02:18 PM

Here is Cmd Promt Script that gives 3 choice

Demo_Menu.cmd
@Echo Off
CLS
COLOR 9F
MODE 62,9
TITLE Demo Menu

:Main
CLS
Echo.
Echo  This Is To Turn On Or Turn Off The Hiberfil.sys
Echo.
Echo   Type 1 For This Choice
Echo   Type 2 For This Choice
Echo   Type Quit To Close Window
Echo.

SET Choice=
SET /P Choice=Type Choice Then Press Enter: 


IF /I '%Choice%'=='1' GOTO Item1
IF /I '%Choice%'=='2' GOTO Item2
IF /I '%Choice%'=='quit' GOTO TheEnd


ECHO "%Choice%" is not valid. Please try again.
SET /P = Press Enter To Continue
GOTO MAIN


:Item1
CLS
Echo.
Echo You Selected Choice 1
ping -n 3 127.0.0.1>nul
Goto TheEnd


:Item2
CLS
Echo.
Echo You Selected Choice 2
ping -n 3 127.0.0.1>nul
Goto TheEnd

:TheEnd
Exit

Attached File(s)



#3 User is offline   MitsuMan 

  • Member
  • PipPip
  • Group: Members
  • Posts: 146
  • Joined: 12-March 06

Posted 28 September 2012 - 10:43 AM

Hello

Thank you very much for the help ;)

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

2 User(s) are reading this topic
0 members, 2 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2013 msfn.org
Privacy Policy