To download NI software, including the products shown below, visit ni.com/downloads.
Overview
This example shows how to drag frontpanel by using mouse events with LabVIEW.
Description
This is a VI I have used a few times when I want to hide the normal bar at the top of a window, but still, want the user to be able to move the window around. I either have my own bar at the top (made from some control) or just want to let the user click and drag anywhere on the Front Panel to move it around. Position FP on Mouse Down.vi is to be used in a Mouse Down event and will reposition the calling VI's front panel for as long as the user holds down the left mouse button.
The Mouse Down event in the Example.vi is for the Pane, so you can click and drag anywhere on the Front Panel to move it around. As mentioned above, you can add any control and use the Mouse Down event for that control.
Requirements
Software:
Steps to Implement or Execute Code
1. Run VI.
2. Click, hold, and drag anywhere on the Front Panel.
Additional Information or References
*This document has been updated to meet the current required format for the NI Code Exchange.**
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.
can you send me this file with labview 8.6 version....?
if i use this vi, it can be change in position only. but can i able to resize the panel....even if i hide my tittle bar?
I saved an 8.6 version and added it. You can still rezise the window without the title bar. All of these settings are in File >> VI Properties >> Window Appearance >> Customize... I recommend just playing around with them to see what they do.
Another note: If you don't need the mouse reference wire for anything else (like in the example) you can just put the open/close for the mouse inside of positionFPonMouseDown.vi. It's probably a little less efficient but it cleans things up a bit and behaves the same.
Thanks Brinoceros,
this is will be very helpfull for my project.