Announcement

Collapse
No announcement yet.

.bat file not working as intended

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

    .bat file not working as intended

    hello,

    I have a small problem wich is the following:

    when I try to execute the command:

    c:\Irfanview\i_view32.exe c:\images\scv.bmp /pos (550,801) /hide=15
    through the command line it works perfectly
    yet when I try to use it in a batch file with the following content:

    c:\Irfanview\i_view32.exe c:\_sc2\scv.bmp /pos (550,801) /hide=15
    echo test
    pause

    the batch file stalls on the first line, it does show the image but the rest of the .bat file isnt executed. It does execute the rest when I close irfanviewer.

    EDIT:
    some additional info:
    running windows 7 (64 bit)
    and Irfanviewer 4.28


    any idea's on how to fix this?
    Last edited by cutebanana; 17.07.2011, 04:36 PM.

    #2
    Hi,

    try to use the start command for that:

    Code:
    start c:\Irfanview\i_view32.exe c:\_sc2\scv.bmp /pos=(550,801) /hide=15
    Whenever you want to execute your commands asynchronly.

    Stefan
    Last edited by stefan; 17.07.2011, 06:00 PM. Reason: /pos= corrected, thank to Foxy

    Comment


      #3
      1.
      The correct syntax for this parameter is:

      /pos=(x,y)


      2.
      [...] the batch file stalls on the first line, it does show the image but the rest of the .bat file isnt executed. It does execute the rest when I close irfanviewer.

      That’s the correct behaviour and not a bug or something else.
      »Und so, in eurer Verzweiflung, kommt ihr zu mir.«

      Texteditor EmEditor:
      Deutsche Sprachdatei (v7.01) für EmEditor Pro 7.02 (englisch)
      EmEditor Pro 8.06 (deutsch) | Deutsche Sprachdatei (v8) für EmEditor Pro 8.06 (englisch)
      Deutsche Sprachdatei (v9.16) für EmEditor Pro 9.17 (englisch)

      Comment


        #4
        Originally posted by stefan View Post
        Hi,

        try to use the start command for that:

        Code:
        start c:\Irfanview\i_view32.exe c:\_sc2\scv.bmp /pos=(550,801) /hide=15
        Whenever you want to execute your commands asynchronly.

        Stefan
        Thanks for the quick response this solved my problem.

        Thanks alot!

        Comment

        Working...
        X