This is a migrated thread and some comments may be shown as answers.

RadGrid client-side selection throws exception

2 Answers 95 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Brian Mains
Top achievements
Rank 1
Brian Mains asked on 24 Sep 2009, 01:28 PM
Hello,

On row click, I was going to programmatically select a row by attaching to the client-side RowClick, and doing:

sender.get_masterTableView().get_dataItems()[e.get_itemIndexHierarchical()].set_selected(true);

Since I can  get to the item index via the event, and select it with set_selected.  But this throws an exception, on the line of:

this._owner._owner._selection._selectRowInternal

But _selection is null, why is that?

Thanks.

2 Answers, 1 is accepted

Sort by
0
Accepted
Princy
Top achievements
Rank 2
answered on 24 Sep 2009, 02:00 PM
Hi Brian,

Have you set AllowRowSelect property to True?

       <ClientSettings  AllowDragToGroup="true">
              <Selecting AllowRowSelect="true" />
              <ClientEvents OnRowClick="OnRowClick" />
        </ClientSettings>

Thanks,
Princy.
0
Brian Mains
Top achievements
Rank 1
answered on 24 Sep 2009, 02:34 PM
I was missing that, thanks.
Tags
Grid
Asked by
Brian Mains
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Brian Mains
Top achievements
Rank 1
Share this question
or