Hi,

Im looking for some code to make a basic program.

All i want is a exe file that you run and brings a box up with 6 choices,
and you select your choice and it loads the relevant program. The programs
will be old DOS stuff launched from bat files so the vb code needs to
execute bat files. Im not really any good at programming myself im looking
for some code to modify to suit my needs if anyone has anything similar they
can advise me of ? I currently run this using a DOS menu program, but seem
as the clients are windows it would look tidy to make a windows app to
launch them.

Thanks

Re: basic menu script by adyda

adyda
Wed Aug 18 14:30:43 CDT 2004


"Duncan Newell" <duncan@NOSPAMsystemtek.co.uk> ha scritto nel messaggio
news:412347fa$0$193$db0fefd9@news.zen.co.uk...
> Hi,
>
> Im looking for some code to make a basic program.
>
> All i want is a exe file that you run and brings a box up with 6 choices,
> and you select your choice and it loads the relevant program. The
programs
> will be old DOS stuff launched from bat files so the vb code needs to
> execute bat files. Im not really any good at programming myself im
looking
> for some code to modify to suit my needs if anyone has anything similar
they
> can advise me of ? I currently run this using a DOS menu program, but
seem
> as the clients are windows it would look tidy to make a windows app to
> launch them.
>

try this:
ProgramList= "1-myProg1"&vbCrLf
ProgramList= "1-myProg1"&vbCrLf
ProgramList= "1-myProg1"&vbCrLf
choice=inputBox("Make Your Choice: & vbCrLf & vbCrLf)



Re: basic menu script by adyda

adyda
Wed Aug 18 14:43:23 CDT 2004


"Duncan Newell" <duncan@NOSPAMsystemtek.co.uk> ha scritto nel messaggio
news:412347fa$0$193$db0fefd9@news.zen.co.uk...
> Hi,
>
> Im looking for some code to make a basic program.
>
> All i want is a exe file that you run and brings a box up with 6 choices,
> and you select your choice and it loads the relevant program. The
programs
> will be old DOS stuff launched from bat files so the vb code needs to
> execute bat files. Im not really any good at programming myself im
looking
> for some code to modify to suit my needs if anyone has anything similar
they
> can advise me of ? I currently run this using a DOS menu program, but
seem
> as the clients are windows it would look tidy to make a windows app to
> launch them.

try something like this:

Dim ProgCommand(4)
ProgCommand(1)="notepad"
ProgCommand(2)="explorer"
ProgCommand(3)="iexplore"
ProgCommand(4)="calc"

Set WshShell = Wscript.CreateObject("Wscript.Shell")
ProgramList= "1-" & ProgCommand(1) & vbCrLf
ProgramList=ProgramList & "2-" & ProgCommand(2) & vbCrLf
ProgramList=ProgramList & "3-" & ProgCommand(3) & vbCrLf
ProgramList=ProgramList & "4-" & ProgCommand(4) & vbCrLf
myMsg="Make Your Choice [1 to 4]:" & vbCrLf & vbCrLf & ProgramList

choice=inputBox(myMsg)
WshShell.run ProgCommand(choice)

set WshShell=nothing

Bye


--
adyda for peace