ZaapR

ZaapR ZAAP


ZaapR is a ZTreeWin Assistant Application (ZAAP) which launches a third party application.
Read Warning BEFORE use

It is started from a command line (or shortcut).
ZaapR [switches] Application Parameters
e.g.
/eJPG "C:\Program Files\IrfanView\i_view32.exe" "%1" /one


Application is the fully qualified path to the executable.
This can be enclosed in quotes if necessary.

Parameters to be passed to application.
Must include at least one replacable parameter %n.

The following replaceable parameters may be used to pass file and directory information to the application.

These should be identical to ZTree Batch parameters, EXCEPT that they will never include quotes.
If the name is likely to need quotes, and the application supports it, include quotes manually e.g. "%1" or "%2:%3\%4.%5"

%1Path and namee.g. C:\1997\December\Test_File.txt
%2Drive lettere.g. C
%3Directory pathe.g. \1997\December
%4Namee.g. ))Test_File((
%5Extensione.g. txt
%6Current directorye.g. December
%7Short path and namee.g. C:\1997\DECEMB~1\TEST_F~1.TXT
%8Short namee.g. TEST_F~1.TXT


Switches:-
/eExtFilter extensions to pass to application
Multiple extensions can be specified e.g. /egif,jpg,tif
(this is interim code - short extensions e.g. htm will match longer strings e.g. html)
/fprocess Files (default)
/dprocess Directories
/pprocess Path (Files & Directories)
/tnnnzbar timer polling interval, in milliseconds e.g /t500 (default 300)
/zPathPath to zbar.dat e.g. /z"C:\Program Files\ZTree"
NOTE this must not include trailing '\'
The method ZaapR uses to locate Ztree is much improved. This should not be necessary, unless you have renamed ztw.exe.


Usage:-
ZTreeWin needs to have the ZAAP feature enabled (by use of the /ZB command line switch).
ZTreeWin Version 1.49.2e or later is required.

After first launching the application, it will be necessary to return to ZTree with Alt+Tab or a mouse click.

ZaapR can be paused with Shift+Ctrl+S, and resumed with Shift+Ctrl+R. This is useful if you need to scroll through a lot of files on ZTree.
Shift+Ctrl+Q eXits.

Shift+Ctrl+Alt+R Restores the minimised ZaapR window
Shift+Ctrl+Alt+N miNimises the ZaapR window

It is recommended that you use a ZTree Filespec or Extension Filter to avoid passing unsupported files to an application.

ZaapR creates a small (50 * 10) window, which displays details of the current zbar target and parameters.
The first 8 lines are the replacable parameters
The 9th is the Application string
The 10th is the Parameters passed to Application, after substitution.
This window is normally Minimised, but it can be restored, moved or resized as required.
(This was originally intended as a development tool, but users requested that it be retained.
Earlier releases also displayed the current zbar contents, if you are interested in these use ZbarView.)

Launching ZaapR from ZTree:
If ZaapR is started from ZTree eXecute (or Alt+X eXecute) double percent signs (%%n) must be used for replacable parameters. If ZaapR is started from ZTree Application Menu (F9) (%%%%n) must be used. (See ZTree help 3.4 Batch Parameters)

ZaapR must be started in asynchronous mode so control is returned and ZTreeWin continues to operate. (See ZTree help 2.11 Launching Programs)

The following Application Menu item starts IrfanView:-
START "" "C:\Program Files\ZTree\ZaapR.exe" "C:\Program Files\IrfanView\i_view32.exe" "%%%%1" /resize=(640,480) /aspectratio /one


Installation:
Extract ZaapR.exe into any directory and execute.
No installation is needed.
ZaapR does not modify the Registry or create any files on your computer.

ZaapR determines the location of the ZTreeWin directory by looking for an instance of ZTreeWin, and will wait if one is not running.

Limitations:-
  • ZaapR is only useful with applications which can be limited to a single instance.
  • After first launching the application this will have focus, and it is necessary to return to ZTree with Alt+Tab or a mouse click.
    With some applications, it may be necessary to repeat this several times. Minimising other programs, so the desktop is not too cluttered seems to help.
  • If you scroll through files in ZTree too quickly, it may cause the application to lockup.
    ZaapR has no way of knowing when the application is ready for a new file.
    You can slow down the rate at which ZaapR polls zbar.dat, and thus attempts to launch new files by setting the zbar timer polling interval (/t). If you make this too large, response will slow. It is better to suspend ZaapR if navigating through a lot of files.
  • ZaapR is not guaranteed to work with Win98 or ME.

Applications:
ZaapR has been used with the following applications.
You may want to modify the individual application switches to suit your needs.
IrfanView
"C:\Program Files\ZTree\ZaapR.exe" "C:\Program Files\IrfanView\i_view32.exe" "%1" /resize=(640,480) /aspectratio /one

Media Player Classic:
"C:\Program Files\ZTree\ZaapR.exe" "C:\Program Files\K-Lite Codec Pack\Media Player Classic\mplayerc.exe" "%1"

Windows Media Player 6.4:
"C:\Program Files\ZTree\ZaapR.exe" "C:\Program Files\Windows Media Player\mplayer2.exe" "%1"

Windows Media Player 9 or 10:
"C:\Program Files\ZTree\ZaapR.exe" "C:\Program Files\Windows Media Player\wmplayer.exe" "%1"

Quick View Plus:
"C:\Program Files\ZTree\ZaapR.exe" "C:\Program Files\Quick View Plus\Program\QVP32.exe" "%1" -x


Download ZaapR.zip(external link).

The full source code is available from ZaapRSource.zip(external link).
Zbar library source in ZbarSource.zip(external link) is also required.

ZaapR includes Copyright code by Elias Bachaalany, use is subject to the conditions in "copyright.txt".

WARNING Read BEFORE use


ZaapR is desiged for use with applications which use a single instance to open files in read mode e.g. file viewers.

Attempts to use applications which modify files can cause wholesale changes to your system.

Applications which open a new instance for each file can be used with care, but it is easy to overload your system.

Contributors to this page: admin and ian .
Page last modified on Friday 01 of June, 2007 09:04:00 EDT by admin.