5 Replies Latest reply on Apr 13, 2009 5:36 PM by danpixley

    Is it possible to see batch files run?

    Spartan Apprentice

      Good Day,

       

      I was wondering if anybody knew how to make a batch file run visually?

       

      I'm Provisioning using the Provisioning Templates:

       

      My "setup" based drivers are installed via batch file when Windows XP first Launches using Run Once.

      This works well but other then the provisioning window this leave little indication that anything is happening.

      As this tasks takes about 10-15 minutes to run I have had people turn off machines thinking the process got hungup.

       

      I added Echo command in the file at each stage but they only show in the provisioning window when the batch finishes it's run.

       

      BONUS question: Rather then seeing the batch file run would it be possible to have the batch file send updates to the provisioning agent (which would show up in the provisioning window)?

       

      Thanks for your help.

        • 1. Re: Is it possible to see batch files run?
          Apprentice

          have you tried to make the batch file called by the provisioning agent spawn a separate batch file? if provisioning spawns a 'startrun.bat' which then runs cmd /c yourbatchfile.bat I think it'll defeat the UI supression.

          • 2. Re: Is it possible to see batch files run?
            Spartan Apprentice

            BizCartaDthompkins wrote:

             

            have you tried to make the batch file called by the provisioning agent spawn a separate batch file? if provisioning spawns a 'startrun.bat' which then runs cmd /c yourbatchfile.bat I think it'll defeat the UI supression.

             

            Sorry about the delay in my response,

             

            I had tried to call it from another batch file but not in it's own shell, I tried this as it seemed promising but no dice

             

            =o(

            • 3. Re: Is it possible to see batch files run?
              zman Master

              You could script a very easy Autoitscript/vbscript that pops up a progress and kill it at the end.

              1 of 1 people found this helpful
              • 4. Re: Is it possible to see batch files run?
                Spartan Apprentice

                zman wrote:

                 

                You could script a very easy Autoitscript/vbscript that pops up a progress and kill it at the end.

                 

                Good Call,

                 

                While this does not give an exact statues of what's going on it certainly let's the end user know something is happening.

                 

                Which solves the root of my problem =o)

                 

                Thanks for the advice zman!

                • 5. Re: Is it possible to see batch files run?
                  Apprentice

                  I found a way to run Echo commands from a batch file in OSD.  I am not sure if this will work in Provisioning or not.  For example, in my hardware independent imaging OSD script, I have the following line:

                   

                  REMEXEC414=cmd /c s:\tools\copydrivers.bat

                   

                  Echo is supressed in OSD the same way it is in Provisioning, so I got around it by using the following commands for the copydrivers.bat file:

                   

                  @ECHO OFF

                   

                  cmd /C "ECHO Please wait for the drivers to copy... && s:\tools\copydrivers.exe /c"

                   

                  Calling another command window from the OSD command is another way to escape the supression of Echo.