Need help with custom Open action item

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello All,

First off, this is my THIRD time posting this same question (first time in
this newsgroup), so I'm hoping to at LEAST get a response from SOMEONE.

I have installed a CAD software called Unigraphics NX3 (NX3 for short).
This install associates all files with the extension PRT with NX3, and double
clicking a PRT file results in the file opening in NX3 just fine, no matter
the location or directory/folder name. That all works just fine.

My issue comes up when using a batch file that forces the software to run
through a customized environment. The new open action is now defined as
follows:

"D:\UGNX3\NX3_Toolkit\gmlaunch4d\gmlaunch4d.bat" -ASSOC=Native -RETRIEVE="%1"

This works fine until I try to open a file from a folder/directory with
spaces in the filename. Can anyone tell me what I'm missing from above? I'm
not an expert at this by any means, but I am pretty sure everything is fine
until the last switch/argument or whatever it's called ("%1"). Is there
another switch/argument that can be used? To reiterate, everything up to
RETRIEVE is necessary & not affecting the outcome.

Thanks in advance,

Tim
 
Tim said:
Hello All,

First off, this is my THIRD time posting this same question (first time in
this newsgroup), so I'm hoping to at LEAST get a response from SOMEONE.

I have installed a CAD software called Unigraphics NX3 (NX3 for short).
This install associates all files with the extension PRT with NX3, and
double
clicking a PRT file results in the file opening in NX3 just fine, no
matter
the location or directory/folder name. That all works just fine.

My issue comes up when using a batch file that forces the software to run
through a customized environment. The new open action is now defined as
follows:

"D:\UGNX3\NX3_Toolkit\gmlaunch4d\gmlaunch4d.bat" -ASSOC=Native -RETRIEVE="%1"

This works fine until I try to open a file from a folder/directory with
spaces in the filename. Can anyone tell me what I'm missing from above?
I'm
not an expert at this by any means, but I am pretty sure everything is
fine
until the last switch/argument or whatever it's called ("%1"). Is there
another switch/argument that can be used? To reiterate, everything up to
RETRIEVE is necessary & not affecting the outcome.

Thanks in advance,

Tim


You'd possibly get more mileage out of alt.msdos.batch.nt for batch
questions

at an educated guess, I'd try changing the "%1" (which means the first
argument where spaces delimit the arguments; therefore an argument of MY
FILE.TXT would be interpreted as MY)

to "%*"

HTH

....Bill
 
billious said:
You'd possibly get more mileage out of alt.msdos.batch.nt for batch
questions

at an educated guess, I'd try changing the "%1" (which means the first
argument where spaces delimit the arguments; therefore an argument of MY
FILE.TXT would be interpreted as MY)

to "%*"

HTH

....Bill

Bill,

I really appreciate your help. Unfortunately, "%*" didn't do the trick
either, as now the software is not reading the full path and file name, but
stopping at the very last directory & trying to read that in place of the
file name. For example, the file I want to open, part.prt, resides in
D:\Program Files\UGS\NX 3.0\DXFDWG. Using "%*" in place of "%1" causes the
software to use DXFDWG as the file name, which it can't open.

I wasn't aware there were other newsgroups, as I am accessing this via a
browser through Microsoft's website. I'll look for the batch files
newsgroups. Thanks so much.

Tim
 
Back
Top