Hi,
When the popup is called, LV cannot continue it's while loop, because it
needs a value from the dialog. This is the same for every function that
takes a long time to finish ( a 5000 wait will hold up the loop 5 seconds, a
dialog will hold up until it's done).
Trick is to do the windows popups in a seperate loop. The difficult part is
to synchronise the two loops. But this can be done;
Make a parallel while loop, with a case in it. The case is wired to a local
boolean "file popup".
If file popup is true, the dialog apreas (note how the other loop is still
running properlly). The "file popup" is set to false.
The main loop sets the "file popup" to true, when the event happens.
When the dialog is done, a boolean indicator "file to load" is set,
as well
as an indicator for the file name.
The main program has a case in it. When "file to load" is true, it resets
"file to load", and does the loading stuff.
Regards,
Wiebe.
"Tobe"
wrote in message
news:5065000000080000002C570000-1027480788000@exchange.ni.com...
> Hello,
>
> When an event occurs my front panel locks. On my front panel I have a
> XY-chart and alot of knows and buttons. What I want to do is to use a
> menu item to save and load files, a file dialog should pop up. This
> seams impossible. It always results in one of the following:
>
> 1. Front panel locks.
> 2. Front panel works but no sign of the file dialog.
> 3. You can call the file dialog once (this is if I put the mane
> outsude the while loop).
>
> I've found alot of questions about this is your forums but I never
> once saw a sollution for it. Can I run the file dialog as a seperate
> thread? Events seam to lock the panel (not just the menu item calls -
> but all events). How do I create a th
read? I don't know what to do.
>
> Regards,
>
> /Thomas