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

deselecting a row in a radgrid strips all its styles

1 Answer 65 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bandana
Top achievements
Rank 1
Bandana asked on 23 Nov 2010, 10:55 PM
Hello,

I have a radgrid with different colors for alternating rows (gray and white) and the selected row is yellow. Only one row can be selected at a time.

<AlternatingItemStyle BackColor="GhostWhite" />
<ItemStyle BackColor="LightGray" />
<SelectedItemStyle BackColor="Lightyellow" />

When I select a row its backcolor becomes yellow. When i select another row, the previous selection loses all its color. how do i retain the LightGray and GhostWhite color on deselecting a row.

Thanks!

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 24 Nov 2010, 10:34 AM
Hello,

 I have got the same issue at my end and one suggestion to overcome this issue is to modify the preset css class of the selected row, instead of SelectedItemStyle.

CSS:
<style type="text/css">
        .rgSelectedRow
        {
          background-color:Yellow !important;
          background-image: none !important;
        }
</style>

Regards,
Shinu.
Tags
General Discussions
Asked by
Bandana
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or