Program parameters needed

Ask for help and post your question on how to use XnView Classic.

Moderators: XnTriq, xnview

Post Reply
JStockton
Posts: 7
Joined: Fri Dec 19, 2014 7:14 pm

Program parameters needed

Post by JStockton » Tue Jan 13, 2015 6:30 am

I often have need to open a file in XnView with another program (Opne With"), but when I do I need to add commandline parameters to the program's EXE. But I do not know if you can specify any such program parameters when you "Add Program." if you try, you get the eror message that says the program name is invalid.

Also, it would be handy to have file properties like current XnView filename, file path, extension, etc., passable so that sophisitcated commandline parameters can be built when adding a "Open With" program. I am often forced to use FastStone which has all these features when jumping to another program. I often time need to pass the filename to a macro program to perform multistep operations

It woud also be nice to jump to a program from not just a highlighted file, but also a highlighted folder.

User avatar
XnTriq
Moderator & Librarian
Posts: 5456
Joined: Sun Sep 25, 2005 3:00 am
Location: Ref Desk

Re: Program parameters needed

Post by XnTriq » Tue Jan 13, 2015 7:30 pm

  1. Go to Info » About... to find the INI file location.
  2. Quit XnView.
  3. Open xnview.ini in a text editor.
  4. Go to the [OpenWith] section and add the entries.
  5. Save the changes.
  6. Restart XnView.
XnTriq ([url=http://newsgroup.xnview.com/viewtopic.php?p=120705#p120705]XnView Shell Extension[/url]) wrote:
XnView Wiki (UI-less Settings » [url=http://www.xnview.com/wiki/index.php/UI-less_Settings#OpenWith]OpenWith[/url]) wrote:
  • Name_# (0-x)
    • Sets a custom name for the specified 'Open With' tool.
      Value: String
    Param_# (0-x)
    • Sets a custom command-line parameters for the specified 'Open With' tool.
      Value: String
      Note: The %1 placeholder in the string is replaced with the filename used to launch the 'Open With' tool.
    Working_# (0-x)
    • Sets a custom working directory for the specified 'Open With' tool.
      Value: String

JStockton
Posts: 7
Joined: Fri Dec 19, 2014 7:14 pm

Re: Program parameters needed

Post by JStockton » Fri Jan 16, 2015 6:00 pm

Your solution does not work.

I added "/API TO /L1" for the ZTW (screen resizing parameters) , and now NOTHING happens in XnView.

At least before when there were no parameters, the ZTW program loaded.

Now nothing

I added %1 the the FSVIewer line--and then FastStone did nothing, so I took it out

This is very poor of XnView. For all ther many things it can do, this is a major disappointment!

[OpenWith]
OpenWith_0=C:\Program Files\Adobe\Photoshop Elements 9\PhotoshopElementsEditor.exe
OpenWith_1=D:\Alex\ztree\ZTW.EXE /API /TO /L1
OpenWith_2=C:\Program Files\IView\i_view32.exe
OpenWith_3=C:\Program Files\FastStone\FSViewer.exe

User avatar
XnTriq
Moderator & Librarian
Posts: 5456
Joined: Sun Sep 25, 2005 3:00 am
Location: Ref Desk

Re: Program parameters needed

Post by XnTriq » Fri Jan 16, 2015 6:45 pm

[color=green]xnview.ini[/color] wrote:

Code: Select all

OpenWith_1=D:\Alex\ztree\ZTW.EXE
Name_1=ZTW
Param_1=/API /TO /L1

Post Reply