I have a grid bound to a list<> and I would like to line-through a text in a certain column when clicked on

Hi,


Ive been using sfgrid and Im having problems getting the cell I clicked in order to do 

Cell.AddStyle(new string[] { "text-decoration:line-through;" }); on it so its marked when I click it.


Any thoughts  on how this can be achieved ?



1 Reply

KG Keerthana Ganesan Syncfusion Team August 8, 2022 11:46 AM UTC

Hi Emil Emilsson,


We have analyzed your query and suggest you style the .e-cellselectionbackground CSS class to overcome the issue. Kindly refer to the attached code snippet, output screenshot, and solution file for your reference.


<style>

.e-grid .e-rowcell.e-cellselectionbackground {

    text-decoration: line-through;

}

</style>

Output-min.jpg

Kindly get back to us if you have any further queries.


Regards,

Keerthana.


Attachment: CellSelection_d252f2da.zip

Loader.
Up arrow icon