LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Resizing a .NET Container

Solved!
Go to solution

Hello all,

 

I have a question regarding .NET controls - is it possible to programatically resize the container that the control resides in?  It seems that when you wire up a .NET container, all that are available are the properties associated with the .NET control which resides in the .NET container and not the container itself.

 

Thanks, Matt

0 Kudos
Message 1 of 6
(3,344 Views)

If you right click on the container on the front panel and select create property node, you should find Countainer Bounds->Height and Container Bounds->Width properties.

 

Regards,

Marco

 

 

0 Kudos
Message 2 of 6
(3,337 Views)

Thanks, Marcus.  But as it says above - programatically.  I essentially want the ability to edit the size and placement of the control in the run time environment.

 

Cheers, Matt

0 Kudos
Message 3 of 6
(3,321 Views)

Are you trying to add the control at runtime? The .net container cannot do that per se, the .net container is a LabVIEW placeholder that allows you to right-click and select the control to be added at design time. However, you can add a panel to the container at design time, then dynamically add the controls at runtime. I gave a presentation on using .net in LabVIEW at our local user group a while back. Here is a link to the write up about it. It includes my slides and code showing the use of a .net panel to dynamically create controls.

https://decibel.ni.com/content/docs/DOC-22031

0 Kudos
Message 4 of 6
(3,316 Views)
Solution
Accepted by topic author cirrusio

Hi Matt,

following the suggesiton in my previuos post you will create  a property node that can be used runtime.

 

Regards,

Marconetcontainer.png

0 Kudos
Message 5 of 6
(3,288 Views)

Hmmmm...why is that so hidden.  Thanks a lot Marco.  I actually didn't use this approach, but it is very nice to know this is there.  I am probably missing something but it seems like this is hidden.  Cheers, Matt

0 Kudos
Message 6 of 6
(3,217 Views)