LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Placement of one button dialog window

HI,
I have a VI which in several places uses the One and Two Button Dialog VIs.  All but one of these dialog windows appear in the center of the VI's window when they are called.  The other one, however, randomly appears in the bottom right corner.  Sometimes, after making a change to the VI (anything from resizing the window to changing something on the BD to moving a label), its behavior will change, either moving to the center or back to the bottom right corner.  Other times, it will appear on the center and, upon reloading the VI later, appear in the bottom right corner.  I have yet to notice any real correlation between what affects this change, but consecutive runs of the VI without changes in between do not seem to effect it.
 
The VI is on a single computer and no changes have been made to it during this time.  The One/Two Button Dialog functions are all wired in similar fashion (they are very simple functions, so not much different *could* be done in terms of wiring...).
 
I've mostly ignored the problem, as there are more important parts of the VI to work on, but this little inconsistency is bugging me.  Am I just missing something obvious here, or what?
-Cory
0 Kudos
Message 1 of 8
(3,628 Views)
Hi corys,
which version of labview do you use? Can you upload this special vi? I build a test vi, which calls the one and two button dialog alternately and i can´t get your behavior.
Mike
0 Kudos
Message 2 of 8
(3,616 Views)
Hi Mike,
I'm currently using version 8.5.1.  I can't upload the specific VI, but here's a little test one I wrote that has similar behavior (the second of the two dialogs appears in the bottom of the right screen, not even over the front panel), but I can't get it to change back and forth between this and the behavior I expected, like I can with my original VI.
 
This is setup similar to how I use the One Button Dialog function in my original VI, with the message wiring out from a loop and the boolean value wiring to the edge of another loop.  I can also get the weird behavior by just putting a couple dailog functions one after another in a sequence structure, though.


Message Edited by corys on 06-04-2008 03:03 PM
-Cory
Download All
0 Kudos
Message 3 of 8
(3,600 Views)

Hi Corys,

I have tried running the VI that you have attached and I do not see the behavior you described.  The built-in popup dialog boxes are set to appear in the exact center of the top level VI that calls it.  They do not export any attributes that allow you to change or modify their position, so I am not sure how the location has been altered in any way. 

When you create a brand new project and try to recreate the VI you attached, does it exhibit the same behavior?  If you delete the One Button Dialog function that is appearing in the incorrect location and replace it with a new one, does the position change?  Can you recreate this on another computer, perhaps by creating an executable of the attached code?

Regards,

Lauren

Applications Engineering
National Instruments
0 Kudos
Message 4 of 8
(3,567 Views)

Hi Lauren,

When I created the test, it was within an brand new project.  Also, I've tried deleting and replacing the effected functions, and that didn't seem to have any effect.  I cannot currently transfer it to another computer (LV not available to me at the moment), but I will try that when I can and get back to you.

-Cory
0 Kudos
Message 5 of 8
(3,558 Views)
When an executable is created from the code, the issue seems to go away, even when run on the same computer that it was developed on.  The computer it was developed on is the only computer I presently have access to with LabVIEW, so I cannot test it on other computers aside from the executable.  I did find out a little bit more about it when doing this, albeit nothing to explain why it occurs.
 
If multiple dialog boxes are opened concurrently, they will either all be placed in the correct spot (cascading), or all be placed in the bottom right of the computer screen (cascading).  Also, if a wait of ~900ms is placed in a sequence structure with the function, the dialog box will sometimes appear in the correct spot (maybe 2/3 of the time the vi is run sequentially, as opposed to always in the wrong spot without the wait). 
 
I suppose if the executable runs correctly, this isn't a pressing issue for me.  But still...I'm stumped as to why this is happening...
-Cory
0 Kudos
Message 6 of 8
(3,548 Views)

Corys,

Since this is unexpected behavior, it is definitely something we would like to figure out.  Unfortunately, if we cannot reproduce it on any other computers, it will be different to investigate.  If you are able to reproduce it elsewhere, please let me know so that we can try to address this for any future releases of LabVIEW.

Regards,

Lauren

Applications Engineering
National Instruments
0 Kudos
Message 7 of 8
(3,523 Views)
Hi Lauren,
 
I have yet to reproduce it on another computer.  Beyond that, I've been working on a different project lately, and now going back to the original project or the tests, I am unable to reproduce it even on this computer.  If I can get it to happen again, I'll try to figure out exactly what I did to do it.  For now, though, I can't seem to get it.
 
-Cory
-Cory
0 Kudos
Message 8 of 8
(3,490 Views)