Re: Problem with vpApp (FileSelectionDialog.GetFileName)

Michael Kuperstein - EECS (mkuperst@quibble.eecs.wsu.edu)
Tue, 16 Aug 1994 18:18:22 GMT

In article <CuMHBB.7CE@cwi.nl>, Frank Teusink <frankt@cwi.nl> wrote:
>Hi,
>
>I have a problem with the method GetFileName() of the FileSelectionDialog class.
>It is best demonstrated using the test application DialogTest.py, which seems
>to suffer from the same problem.
>
>When I run DialogTest.py, push the button FileSelectionDialog, and (in that dialog)
>push the button OK (after selecting a file), python crashes with the following
>message:
>
>Traceback (innermost last):
>File "<stdin>", line 1, in ?
>File "./DialogTest.py", line 116, in ?
> test()
>File "./DialogTest.py", line 114, in test
> app.Run()
>File "/ufs/per/src/python/vpApp/lib/Application.py", line 170, in Run
> Xt.MainLoop()
>File "/ufs/per/src/python/vpApp/lib/Dialog.py", line 275, in wOkCB
> self.OkCB( None )
>File "/ufs/per/src/python/vpApp/lib/Dialog.py", line 272, in OkCB
> self.ok_cb( self )
>File "./DialogTest.py", line 102, in CB
> print dialog.GetFileName()
>AttributeError: GetFileName
>
>Does anyone have a clue?

I've been using vpApp for quite some time, and other than a few
minor quirks here and there, it's been very stable, although somewhat
limited in functionality.

I looked at the source, and looked at your code. the last line for
File "./DialogTest.py", line 102, in CB
should be:
print dialog.GetFilename()

Note: non-capitalized n in name.

Don't forget: Case matters.

Here's a possibility for your problems. If you aren't using
the latest version of vpApp (1.3) and at least python 1.0.2, and of
course Motif 1.2, that could be your problem.

Hopefully this should fix it. I've had my share of seemingly
unfixable problems, some of which have taken days to work out.

--
Michael Kuperstein              \(*)|\
mkuperst@eecs.wsu.edu            \ --_\o   --   Ahhhhhhhhhhhhhhh!!!!!!!
Major: Computer Science           \(*)!
Washington State University        \      /\    /\      /\      /\