Announcement

Collapse
No announcement yet.

Command Line Option: capture and convert, but not close irfanview

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

    Requested Command Line Option: capture and convert, but not close irfanview

    Command Line Option: capture and convert (to jpg), but not close irfanview

    or open automatic the converted file with irfanview

    This would be a nice feature, when you want to use (smaller, jpg) screenshots or cropped screenshots in other programes.

    Thank you

    Stephan

    #2
    Support !
    According to the command line options :

    "/convert=filename - convert input file to "filename" and CLOSE IrfanView"

    Indeed I wonder : why is this convert connected with an automatic close of IrfanView ?
    0.6180339887
    Rest In Peace, Sam!

    Comment


      #3
      Hello,

      the answer is simple: batch cnonverting is often used for more than one picture..

      What you like to have is a scripting feature for the Irfan View gui (open an image, call your converting script, wait a moment and see the result).

      If you have a batch call for iview with your common convertation, like convert.cmd, and you will run it
      convert.cmd mypic.jpg
      it is not a big deal to append just
      i_view32.exe %1
      to the end of your batch file.

      Regards, Nils.

      Comment


        #4
        You're absolutely right. My brain must have lost the connection with the DOS 6.22 archives at that moment.
        0.6180339887
        Rest In Peace, Sam!

        Comment


          #5
          capture and convert (to jpg) - one solution

          > Command Line Option: capture and convert (to jpg), but not close irfanview

          This solution works in Win XP (german version):

          1. create a batch-file:

          filename: screenshot_with_irfanview.cmd

          del c:\windows\temp\screenshot.jpg
          C:\Programme\IrfanView\i_view32.exe /killmesoftly
          start C:\Programme\IrfanView\i_view32.exe /capture=1 /convert=c:\windows\temp\screenshot.jpg
          :WAIT
          IF NOT EXIST c:\windows\temp\screenshot.jpg goto WAIT
          start C:\Programme\IrfanView\i_view32.exe c:\windows\temp\screenshot.jpg
          exit /b


          Probably you have to change c:\Programme when you use another language version of XP.

          2. create a link / Verknüpfung to the batch file

          The link should be start with a hotkey (for example STRG/CTRL + F11) and the batch-file must be open minimized. (see the attached picture)

          Now it's possible to create a screenshot of the foreground window (cause capture=1) with the hotkey STRG/CTRL + F11 which will be automatic convert to a jpg-file
          Attached Files

          Comment


            #6
            Hi Stephan (prittstift69)

            Thanks for your suggestion. I made a variation on your batch file (adapted for French and English versions of Windows). It works well for me, with WinXP Pro. Here is a copy.
            Code:
            set IVfile="%TEMP%\screenshot.png"
            set IVprog="%ProgramFiles%\IrfanView\i_view32.exe"
            if exist %IVfile% del %IVfile%
            start "" /wait %IVprog% /capture=1 /convert=%IVfile%
            start "" %IVprog% %IVfile%
            exit /b
            Since the start command allows the /wait switch, I used it instead of the loop :WAIT ... goto WAIT. I also used environment variables when possible.

            Laurent
            Before you post ... fill in your OS and IV version in your profile.

            Comment

            Working...
            X