LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Table control, Unkillable Edit Position returns to cell 0,0

Solved!
Go to solution

I have a problem with Table control. All what I need:

Select one cell in the table (no multiple selection, no zero selection, no editing).

Selection can be limited catching "mouse up" event then reducing selection size. This is probably inventing a wheel but I cannot find anything better. It is Monday after allSmiley Indifferent

 

But the main problem is unkillable EditPosition. This is simple test VI. Despite setting EditPos to (-2,-2), the result is always (0,0). And the position is indicated in Front Panel (but cannot be edited). What is my mistake?

TableTest181029.png

 

Thank you

 

_____________________________________
www.azinterface.net - Interface-based multiple inheritance for LabVIEW OOP
0 Kudos
Message 1 of 4
(3,818 Views)

Look at the help file.  No where does it say that -2 is a valid entry.  It will only return -2 if no edit is being made.

Edit Position Property

Name Description
Row The row of the current text entry. Possible values are 0…n, where n is the total number of rows - 1.
Column The column of the current text entry. Possible values are 0…m, where m is the total number of columns - 1. Enter –1 to select the column header.
aputman
0 Kudos
Message 2 of 4
(3,796 Views)
Solution
Accepted by topic author _Y_

Thank you aputman for reply. It does not solve the problem but shows my mistake.

 

I have found solution for my  problem

Select one cell in a Table (no multiple selection, no zero selection, no editing).

It works for both Table control and Table indicator. Not so obvious or elegant but it works:

 

 

TableTest181030.png

 

 

_____________________________________
www.azinterface.net - Interface-based multiple inheritance for LabVIEW OOP
Message 3 of 4
(3,769 Views)

Hi _Y_, your solution doesn't quite work for me because I need the table to be scrollable which is disabled when the control is disabled.  However, it led me to a solution to capturing the cell clicked without invoking an edit.  Through testing I noticed that the cell edit is activated on Mouse Down.  So, I created an Event Case via Mouse Down? to handle and discard the Mouse Down event.  This kept the Table Control from activating the edit on the cell clicked.  Like you, I then used the Mouse Up event to perform my operations on the cell and the information contained within it.  Thanks for the breadcrumbs!  

 

TableControlCellSelectWithoutEdit.png

 

-

Regards,
Paul
0 Kudos
Message 4 of 4
(2,057 Views)