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

Spreadsheet Unselected Cell Class

2 Answers 134 Views
Spreadsheet
This is a migrated thread and some comments may be shown as answers.
Marc
Top achievements
Rank 1
Marc asked on 11 Jan 2017, 10:54 AM

Hi, can you tell me the class used to apply the background colour and font colour to the normal (unselected) spreadsheet cells?

Thanks!

MArc

2 Answers, 1 is accepted

Sort by
0
Accepted
Dimiter Topalov
Telerik team
answered on 13 Jan 2017, 08:20 AM
Hello Marc,

The Spreadsheet cells DOM elements have class "k-spreadsheet-cell", and their style can be manipulated via CSS using this selector:

http://dojo.telerik.com/EzEYE/3

However most of the styles are inherited from other ancestor elements like "div.k-widget.k-spreadsheet" and "div.k-spreadsheet-view".

You can use the browser's developer tools console to get the cells via jQuery (e.g. $('.k-spreadsheet-cell');) and inspect the cells with the elements inspector to see the full list of styles, and where they are coming from.

Regards,
Dimiter Topalov
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Marc
Top achievements
Rank 1
answered on 13 Jan 2017, 09:08 AM

Hi Dimiter

Thanks for the very detailed reply! I am changing the background colour of a cell if a certain condition is met, but the user can change things, which mean I need to revert the background colour of the cell. 

This class worked perfectly - thank you!

Tags
Spreadsheet
Asked by
Marc
Top achievements
Rank 1
Answers by
Dimiter Topalov
Telerik team
Marc
Top achievements
Rank 1
Share this question
or