Printable Version of Topic

Click here to view this topic in its original format

PMView Pro Forums _ PMView - General Discussion _ Convert Scripts Using Relative Path Output

Posted by: bcRIP Jan 16 2006, 04:26 PM

Hi,

This has been an issue recently that I have discovered, and it smells like it might be a bug.

When I am in Open Preview mode and I have selected one or many images to perform a Convert operation, one of the options use is the "Set Output Directory" option. I have discovered a problem if I try to use a relative path.

Here is an example:

I start with my first set of images here "D:\testimages1\original"
I set the output directory to: "..\revised"
...which outputs my files correctly to "D:\testimages1\revised"

But then I go to my next job...

I start with my second set of images here "D:\testimages2\original"
I do not modify the output directory as I still want it to go to "..\revised",
relative to the source directory.
I run the job and it ouputs my files to "D:\testimages1\revised"

Not the expected behaviour I was hoping for. Can this be fixed?

I have experienced this as recently as v3.22 under Windows and have not
tested this under OS/2, but if it a problem there as well, it would be great
if it was fixed there too.

Thanks!

Posted by: Peter Jan 18 2006, 10:16 AM

It's a "feature" that dates back to the command line days. Relative paths in PMView are relative to the current working directory, i.e. the directory where you started PMView, not relative to the file open dialog.

Of course, fixing this will break it for command line users that expect the current behavior...

I'll see if I can work around this problem by having the File Open dialog resolve the paths relative to the viewed directory before passing it on to the conversion engine...

Thanks,

Posted by: bcRIP Jan 18 2006, 09:11 PM

Ah, I see. That makes sense. What about a checkbox in the GUI where you can
specify in the "Set Output Directory" settings that it applies to "relative to source file" or something of that nature? Just an on/off optional toggle.

Anyways, even without the change the program is great. Thanks as always for all the hard work! smile.gif

Posted by: Peter Jan 20 2006, 07:00 PM

The problem here is the concept of what the "current working directory" (CWD) is. I've gotten at least one other bug report about this. It is obvious that when working from the FOC, one expects the CWD to be the directory viewed in the FOC and not the command line CWD.

After considering all aspects, I think that the whole issue will be fixed if I code PMView to resolve the CWD relative to the FOC directory if the script is launched from the FOC popup menu or from the main menu. However, if the script is lauched from the command line, then the command line CWD will be used.

This should resolve the problem without causing problems for command line users. This fix will be in v3.24.

Thanks,

Posted by: bcRIP Jan 22 2006, 07:33 PM

QUOTE (Peter @ Jan 20 2006, 08:00 PM)
This should resolve the problem without causing problems for command line users. This fix will be in v3.24.

Thanks,
*


No, no. Thank you! smile.gif

Posted by: bcRIP Feb 22 2006, 01:09 AM

I saw the new download. Thanks again =D

Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)