Announcement

Collapse
No announcement yet.

Batch file help needed

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Batch file help needed

    I want the choice 1 or 2 to start as soon as the button 1 or button 2 are pressed how do I do this see below this is what I have so far
    the choice is for 2 different startup options for jukebox software for a mate and his son 2 very diffrent tasts in music
    os is winxp sp2
    At the moment you need to press enter after making the choice

    @echo off
    CLS
    echo.
    echo SHED JUKEBOX FROM HELL
    echo.
    echo.
    echo.
    echo Welcome to the "SHED JUKEBOX FROM HELL".
    echo
    CLS
    echo Please choose start up option:
    echo.
    echo.
    echo 1. Stevies Music:
    echo.
    echo 2. Phillips Music:
    echo.
    echo.
    echo Please choose an option:
    pause
    set /p choice=Enter a number:
    if %choice% == 1 GOTO STEVE
    if %choice% == 2 GOTO PHILLIP

    :STEVE
    c:
    cd\jukebox
    cd steve
    START wincab.exe
    GOTO ENND

    HILLIP
    CLS
    c:
    cd\jukebox
    cd phillip
    START wincab.exe

    :ENND
    The best action is wrist action!!!!!!

  • #2
    Create a text file with the choices in it and have the batch file read the text file. Eg:

    echo 1 > answer.txt
    echo 2 >> answer.txt
    menu.bat < answer.txt

    Can't remember the exact syntax though

    Brad
    My Projects - Space Invaders Bartop, Williams A-Go-Go, Galaxian Bartop, Jukebox Kiosk 1&2, Jukebox Kiosk 3, Virtual Minipin, Generic Upright, MultiCab, Rampage,

    Comment


    • #3
      Code:
      @echo off
      CLS
      echo.
      echo SHED JUKEBOX FROM HELL
      echo.
      echo.
      echo.
      echo Welcome to the "SHED JUKEBOX FROM HELL". 
      echo
      CLS
      echo Please choose start up option:
      echo.
      echo.
      echo 1. Stevies Music:
      echo.
      echo 2. Phillips Music:
      echo.
      echo.
      CHOICE /C 12 /N /M "Please choose an option:"
      IF ERRORLEVEL 1 GOTO STEVE
      IF ERRORLEVEL 2 GOTO PHILLIP
      
      :STEVE
      c:
      cd\jukebox
      cd steve
      START wincab.exe
      GOTO ENND
      
      :PHILLIP
      CLS
      c:
      cd\jukebox
      cd phillip
      START wincab.exe
      
      :ENND
      Check out our free iOS game .

      Comment


      • #4
        Yay, even better.

        The one I did is for not requiring any entry at all eg: unattended

        Brad
        My Projects - Space Invaders Bartop, Williams A-Go-Go, Galaxian Bartop, Jukebox Kiosk 1&2, Jukebox Kiosk 3, Virtual Minipin, Generic Upright, MultiCab, Rampage,

        Comment


        • #5
          Hmmm CHOICE is not recognised as an internal or external command,operable command or batchfile
          The best action is wrist action!!!!!!

          Comment


          • #6
            Originally posted by Davefjedi View Post
            Hmmm CHOICE is not recognised as an internal or external command,operable command or batchfile
            It's in the reskit (Resource Kit). You can find a matching reskit for your OS on Microsoft's site, or via google.
            | |

            Comment


            • #7
              Originally posted by elvis View Post
              It's in the reskit (Resource Kit). You can find a matching reskit for your OS on Microsoft's site, or via google.

              Im a nooob
              The best action is wrist action!!!!!!

              Comment


              • #8
                Hrm I was certain it was in the reskit.

                The 32bit Windows Server 2003 reskit will work on 32bit Windows XP:
                http://www.microsoft.com/downloads/d...displaylang=en

                But it doesn't seem to have the "choice" command in there. I'm confuzzled...

                Any Microsoft guys here know where to get it (safely)?
                Last edited by elvis; 21st November 2008, 07:57 AM.
                | |

                Comment


                • #9
                  What about installing wincab into 2 different directories, and setting each up to use thier own song folders, then use a frontend like MaLa to select which persons music style you want to listen to ?

                  Comment


                  • #10
                    May need to do that I wanted to keep it simple batch is working just need to push enter to select I was wanting to just have to push 1 or 2 and have it continue on from there
                    The best action is wrist action!!!!!!

                    Comment


                    • #11
                      choice was in the NT resource kit, not sure about kit's after.

                      best bet is if you (or someone) has a Dos 6 or 95/98 install it should be in those by default, just copy choice.com over and it should work fine

                      Comment


                      • #12
                        Originally posted by Brootal View Post
                        choice was in the NT resource kit, not sure about kit's after.

                        best bet is if you (or someone) has a Dos 6 or 95/98 install it should be in those by default, just copy choice.com over and it should work fine
                        Yeah I got a copy off of fraggles mame boot cd but it dosent work to well
                        well looks like I may need to install Delphi and go from there create an executable to do what i want here comes a 7 day project to chose 1 or 2 options
                        The best action is wrist action!!!!!!

                        Comment


                        • #13
                          Here it is
                          Attached Files
                          Check out our free iOS game .

                          Comment


                          • #14
                            Ahh ,, choiiice maaate

                            Comment


                            • #15
                              Originally posted by AdamC View Post
                              Ahh ,, choiiice maaate
                              LMAO! Good ol' bogan saying that one. Why don't the youth of today still use it? I mean 'cool' is still around right? Why not choiiiiceee mmaaaatttee!
                              Check out our free iOS game .

                              Comment

                              Users Viewing Topic: 0 members and 1 (guests)
                              Working...
                              X