Home » U++ Library support » ArrayCtrl, HeaderCtrl & GridCtrl » Retrieving column index like a row
Retrieving column index like a row [message #40484] |
Wed, 07 August 2013 13:31 |
crydev
Messages: 151 Registered: October 2012 Location: Netherlands
|
Experienced Member |
|
|
Hello,
I am using the following code to retrieve the data from the currently selected row in an ArrayCtrl.
const int row = this->mUserAddressList.GetCursor();
if (row >= 0 && mUserAddressList.GetCount() > 0)
{
// The selected row is not -1, so no error will occur when data retrieval is attempted.
}
I am wondering, is it possible to also retrieve the column the cursor is in? I would like to implement different behavior between different columns.
P.S.
I bug I have using this code though, is that since always one row is selected if you click anywhere in the ArrayCtrl, even by clicking outside of a row, still one will be selected. This only applies to a situation where there are less rows then available draw space. Is there a way to fix this? I can imagine I am using the wrong code to retrieve row indexes.
Thanks in advance!
[Updated on: Wed, 07 August 2013 13:32] Report message to a moderator
|
|
|
|
|
Goto Forum:
Current Time: Thu Apr 18 11:27:48 CEST 2024
Total time taken to generate the page: 0.02202 seconds
|