Situation:
I have a form with an empty table. Then I populate the table with a few data rows from a CSV file. No table cell is selected after filling the table.
When I now call table1.SelectedRow the result is 0 ... so I don't know wether no cell was selected so far or wether the first row was really selected.
But I am a clever one :sign0137: ... I defined a global var named actualRow and an SelectionChanged-event:
Problem:
This works only for the first time. After the cell selection is handled by the program I can reset actualRow to -1 but I can't deselect the cell.
And if the user taps on the table header or elsewhere outside the table and deselects the cell, I have no event to get noticed about deselection.
:sign0085:
It would be useful if SelectedRow and SelectedCol would return -1 if no cell is actually selected.
Edit: table1.Refresh or table1.SelectCell("col1", -1) don't deselect.
I have a form with an empty table. Then I populate the table with a few data rows from a CSV file. No table cell is selected after filling the table.
When I now call table1.SelectedRow the result is 0 ... so I don't know wether no cell was selected so far or wether the first row was really selected.
But I am a clever one :sign0137: ... I defined a global var named actualRow and an SelectionChanged-event:
So I'm able to check an explicit cell selection .Sub Globals
actualRow = -1
End Sub
Sub TableEinheiten_SelectionChanged (ColName, Row)
aktRow = Row
End Sub
Problem:
This works only for the first time. After the cell selection is handled by the program I can reset actualRow to -1 but I can't deselect the cell.
And if the user taps on the table header or elsewhere outside the table and deselects the cell, I have no event to get noticed about deselection.
:sign0085:
It would be useful if SelectedRow and SelectedCol would return -1 if no cell is actually selected.
Edit: table1.Refresh or table1.SelectCell("col1", -1) don't deselect.
Last edited: