LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Fixed distance between front panel objects to avoid overlapping...

Solved!
Go to solution

Hello all,

 

I have two arrays expanding depending on the values. If the arrays contain a lot of elements, these two arrays overlap, please see below images.

 

1.PNG

2.PNG

 

How can I keep the distance between those two arrays same, in order to avoid overlapping? These arrays are in a tab.

 

Cheers,

 

Palazzo

0 Kudos
Message 1 of 5
(3,937 Views)
Solution
Accepted by topic author Palazzo

You can do this programmatically, but not in development mode. If the arrays are expanding depending on the values, does that happen programmitcally?

 

You can pull a control's location and bounds using a property node. There's a section of properties in the list that contains Position, Bounds, Master Bounds Rectangle, etc. that can tell you all the info you need to offset the second array. You should be able to pull the Bottom value from Master Bounds Rectangle, add an offset, and set the Position of the second array.

 

Give this a try:

Arrays Bounding Across the FP.png

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


0 Kudos
Message 2 of 5
(3,927 Views)

Nice... Thanks James. I have couple of front panel images and texts which I use as labels-captions though. I have to put them into picture ring or something to use position property...

 

I use "Group" tool a lot, that's why I was asking about the "distance" actually, not control positions... Anyways, I am not willing to get lost into this, thanks for your reply.

0 Kudos
Message 3 of 5
(3,901 Views)

Ah, yeah that's one disadvantage. I think it's an oversight by NI that grouped Front Panel items don't move together when positioned programatically like this.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


0 Kudos
Message 4 of 5
(3,891 Views)

Nevermind! I just realized you can do what you're trying to do using a customized control. Right click your array and go to Advanced >> Customize. Within this control front panel, you can add your caption texts, or images, or whatever and they will always move with the control just like a caption. You don't even have to save the control to file unless you want to duplicate the added captions elsewhere.

 

(I posted a second reply, so that OP doesn't miss the edit.)

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 5 of 5
(3,882 Views)