LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to disable specific columns in table

Solved!
Go to solution

Hi everyone, 

 

There are two buttons in my code (Shift and General). When i press the shift push button, General column should disable & grey out, but all the three shift columns (Shift1, Shift2, Shift3) should be in an editable state. Like below picture,

 

shift.jpg

 

and then the vice versa case (If I press the General push button). Like below picture,

 

general.jpg

 

There is no action in the table If both the push button on high value. I guess surely there is some easy solution, but I couldnt reach there. Figure it out please.

 

Thanks in advance.

0 Kudos
Message 1 of 9
(5,500 Views)

I don't think you can do this with a table control. A workaround is to bundle two tables in a cluster, customize this control so it look lika a single table and then use the disabled property of each table. Attach is a quick example. It doesn't do exactly what you want but it give an idea of how you can achieve it.

 

Ben64

 

 

0 Kudos
Message 2 of 9
(5,485 Views)

It's not perfect, but this is how I do it:

2014-11-25_17-04-20.png

 

This will discard all left-mouse clicks in all columns (but allow you to scroll - for creating a table indicator that doesn't allow you to edit text in the cells). You can unbundle the column from the cell position and if it's not the right column, discard it.

 

It's not perfect because I think it will allow you to use the arrow keys/tab to select other cells.


LabVIEW Champion, CLA, CLED, CTD
(blog)
0 Kudos
Message 3 of 9
(5,482 Views)
Solution
Accepted by topic author Vij@y

Use a semi-transparent image on top of the columns to disable.  Make the decoration visible or not depending on the state of the Boolean.   The columns will still be "enabled" but will not be clickable.

0 Kudos
Message 4 of 9
(5,464 Views)

Hi Zwired1,

 

Your idea was good, but I think there is no need for decoration. I simply done this using two picture control/indicator with its property node (Disabled and Visible). Check the VI below.

 

Thanks ben64 and sam_sharp for your effort Smiley Happy

0 Kudos
Message 5 of 9
(5,441 Views)

Cool. I generally don't like adding indicators for stuff like this but they sure are easier to get references to. 

 

Now, let's see you make it shaded red.... Smiley Happy

0 Kudos
Message 6 of 9
(5,427 Views)

Hi. I realize this is an old thread, I find this information very useful for my application. I am trying to do something similar.

 

How did you create the "new picture" from the table? I attached the .vi that you suggested for your reference. 

 

Thank you!

0 Kudos
Message 7 of 9
(3,111 Views)

Hi. I realize this is an old thread, I find this information very useful for my application. I am trying to do something similar.

 

How did you create the "new picture" from the table?

 

Thank you!

0 Kudos
Message 8 of 9
(3,110 Views)

@TTLN4 wrote:

Hi. I realize this is an old thread, I find this information very useful for my application. I am trying to do something similar.

 

How did you create the "new picture" from the table?

 

Thank you!


The picture control is not created from the table. It is a separate control/indicator/element in LabVIEW. You can use the search function to find it, it is called 2D Picture, or look on the following the Classic Controls Palette, Classic Graph>>Controls>>2d Picture.

 

Snap156.pngSnap157.png

0 Kudos
Message 9 of 9
(3,018 Views)