comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: A problem with pickfile?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: A problem with pickfile? [message #6327] Tue, 04 June 1996 00:00
Tim Patterson is currently offline  Tim Patterson
Messages: 65
Registered: October 1995
Member
Sorry to be generating my own thread here...

Well, I managed to track down my problem, and it appears to be an
inconsitency in the way pickfile works and I can't see this mentioned
in the FAQ...

If I call up pickfile as

file = PICKFILE(GET_PATH = path)

it creates a pickfile widget and I can select a file.
The variable path is always returned correctly, but the
variable file can vary dependent upon how I use the
pickfile widget.

If I click on an already existing file, the path+file names
are copied into the selection widget and returned on pressing
OK. So I end up with

file = /usr/tim/file.dat
and path = /usr/tim/

However, if I type a filename into the Selection widget
to create a new file and press OK, I get:

file = newfile.dat
and path = /usr/tim/

Surely this inconsistency in pickfile is a bug of sorts.
After all, there is no need to copy the path into the selection
widget when it is available at the top of the pickfile widget
already. The documentation says pickfile returns a file name
and doesn't say it returns a complete path.

I guess I'm going to have to add some OS-dependent code into
my routines each time I call pickfile just to make sure
that there is no path already attached to the filename unless
somebody can tell me a clever hack around this...

Tim
Re: A problem with pickfile? [message #6328 is a reply to message #6327] Tue, 04 June 1996 00:00 Go to previous message
Tim Patterson is currently offline  Tim Patterson
Messages: 65
Registered: October 1995
Member
Just as an addition, the pickfile documentation says that

file=pickfile()

should return the file name in the variable "file"
but doesn't make clear anywhere if this should be just the
name of the file or the complete path to the file.
Which _is_ the correct behaviour for this widget?

Thanks again

Tim
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: another composite image question
Next Topic: Re: making a composite from several images

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:51:22 PDT 2025

Total time taken to generate the page: 0.00589 seconds