Detecting Closing of File Object Selector
Is there a way to detect the closing of the file object load selector closing?
I am trying to copy file names into edit boxes when they are selected from the file load file selector. Everything works fine unless the user opens the file load selector and just closes it. I am checking for the file by looking for readable file name selected. But if the load selector is just closed, it places nothing in the edit box and does not turn off. I need a way to see that the selector is closed.
Any help appreciated.
Steve
Re: Detecting Closing of File Object Selector
When the selector is open, your application is stopped. The best way to handle the file selector of the file object is to put its actions in a group, and then to open the selector just activate the group :
Group XXX
- Always / Open Selector
- Do what you want here
- Always / Deactivate Group XXX
You can test if the user has clicked the Open button or the Cancel button by testing if the returned pathname is empty or not.
Re: Detecting Closing of File Object Selector
Instead of using groups, I use fastloops. :)
Re: Detecting Closing of File Object Selector
Ever since I've found the Common Dialog Object to be inconsistant, I've relied on Yves' way of using the File object.
Make sure the group is disabled in your event editor.
Re: Detecting Closing of File Object Selector
Thanks, Yves. That worked perfectly.
Steve