LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Change programmatically the front pannel

Hi GerdW,

 

sorry if i have learnt LabView by myself and i missed some Basic information. I have always thought the comunity as a place to find inspiration to go deeper in my knowledge so thank you for all the points that you have highlighted. I came up with something like this:

 

Zuc_lab2_0-1758633899618.png

 

The only thing is ho can i disable the not used elements? in the picture are the ones with an empty Channel list.

Zuc_lab2_1-1758634087902.png

Thank you very much for the help and the kindness!

 

Best Regards,

Zuc

0 Kudos
Message 11 of 19
(191 Views)

Hi Zuc,

 


@Zuc_lab2 wrote:

The only thing is ho can i disable the not used elements? in the picture are the ones with an empty Channel list.


Again basic LabVIEW knowledge: in an array ALL elements share the SAME properties.

This results in: You cannot disable some elements in an array!

 

There's a reason for the idea/suggestion in my previous message…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 12 of 19
(183 Views)

@Zuc_lab2 wrote:

Hi GerdW,

 

sorry if i have learnt LabView by myself and i missed some Basic information. I have always thought the comunity as a place to find inspiration to go deeper in my knowledge so thank you for all the points that you have highlighted. I came up with something like this:

 

Zuc_lab2_0-1758633899618.png

 

The only thing is ho can i disable the not used elements? in the picture are the ones with an empty Channel list.

Zuc_lab2_1-1758634087902.png

Thank you very much for the help and the kindness!

 

Best Regards,

Zuc


It's easier if you keep it 1 dimensional

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 13 of 19
(169 Views)

Hi Yamaeda,

 

I thought about your advice but the problem is how to manage the possibility to reach also 100 elements since the main front panel that I wish to have is something like:

Zuc_lab2_0-1758695232280.png

 

I’m trying to reduce at minimum the dimension of the cluster but still trying to find also a smarter way.

In the meanwhile do you know any option to live accessible by the scrollbar also active elements of the array? Because my code always shows all the active elements but I need to keep the size of the array in the front panel fixed.

Thank you for the help!

 

Best Regards,

Zuc

0 Kudos
Message 14 of 19
(144 Views)

Hi Zuc,

 


@Zuc_lab2 wrote:

how to manage the possibility to reach also 100 elements since the main front panel that I wish to have is something like:


You could show scrollbars for those array controls.

You can even show/hide them depending on the number of channels…

 

(This will give a bad UX when the user has to scroll too much!)

 


@Zuc_lab2 wrote:

I’m trying to reduce at minimum the dimension of the cluster but still trying to find also a smarter way.

In the meanwhile do you know any option to live accessible by the scrollbar also active elements of the array? Because my code always shows all the active elements but I need to keep the size of the array in the front panel fixed.


You can:

  • Hide the labels of the cluster elements on the frontpanel.
  • Use the control tipstrip to show a comment to the user, so they will know the meaning of each control.
  • Set similar size for each of the 3 cluster elements.

This will reduce the pixel size of each cluster.

I recommend to use System controls to make the UI more "look like standard OS".

 

I still recommend to use a MCLB to show all available channels to the user. (The MCLB also supports scrollbars to show larger lists.)

  • When the user select one channel that channel can be manipulated by 3 controls next to the MCLB. So you will need ONLY ONE cluster (of 3 controls) to handle ALL channels!
  • You can indicate the channel state by either changing background colors of the row in the MCLB or by using the ItemSymbols supported by the MCLB!

I also recommend to not use a LabVIEW error indicator to show errors to the user!

I would use a simple string indicator instead, showing some formatted text in case of errors… (This will reduce needed UI space a lot!)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 15 of 19
(128 Views)

Hi GerdW,

 

That idea can fit my need! you're suggesting something like this:

Zuc_lab2_0-1758704469335.png

So from the list box i take the information i need.

The client ui idea is to have all boolean button to press, a huge ammount to display when needed. 

But how the cluster can change based on the MCLB? Can you show me a simple example?

 

Thank you very much for the help!

 

Best Regards,

Zuc

0 Kudos
Message 16 of 19
(122 Views)

Hi Zuc,

 


@Zuc_lab2 wrote:

But how the cluster can change based on the MCLB? Can you show me a simple example?


  • You can use a value change event on the MCLB to get notified when the user selects a different row.
  • You can read the data for the channel shown in this row and use it to set the values of the "controls".
  • Use value change events of those "controls" to change the data in your datastorage and to update the MCLB items to reflect the data of your datastorage.

Generic advice:

  • Use the MCLB just as indicator for data held in a separate datastorage. (This could be a shift register holding your current array of clusters.)
  • Use a subVI to convert the array of clusters into the 2D array of strings used for the MCLB items.
    (General advice: separate data storage from data presentation on UI.)
  • When presenting larger lists in MCLBs you should know about the DeferPanelUpdate property of the frontpanel and how to use it.
  • I still prefer controls from the System palette. Those Classic controls look ugly (IMHO)… 😄
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 17 of 19
(117 Views)

@Zuc_lab2 wrote:

Hi Yamaeda,

 

I thought about your advice but the problem is how to manage the possibility to reach also 100 elements since the main front panel that I wish to have is something like:

Zuc_lab2_0-1758695232280.png

 


How would this 1D array version work out?

Yamaeda_0-1758879996336.png

 

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 18 of 19
(78 Views)

Hi Yamaeda,

 

Due to time issues, I have choosen to create a certain number of cluster and hide the not used ones by property nodes in a separate VI respect to the Main one.

The front panel is something like this:

Zuc_lab2_0-1759156684113.png

while the VI uses event and property node to manage the clusters input:

 

Zuc_lab2_1-1759156839230.png

 

It isn't so smart for a lot of switches but this was the fastest solution right now.

 

Thak you for the help!

Feel free to add any advice or best practice to improve it.

 

Best Regards,

Zuc

0 Kudos
Message 19 of 19
(28 Views)