Author Topic: how can i make condition css style on cell ?  (Read 1273 times)

alonewolf149

  • Pro Enterprise
  • Jr. Member
  • *
  • Posts: 56
    • View Profile
how can i make condition css style on cell ?
« on: October 05, 2020, 11:02:54 am »
how can i make condition css style on cell ?

i want to get value from DB ex:
http://prntscr.com/ut8gyg

any value i save, it will show on particular cell :
http://prntscr.com/ut8h71

currently i can do by adding span  :
http://prntscr.com/ut8hdi

but i think it wrong way to add, because i saw padding.

can u suggest me the right way ?

Thanks
Thanut


paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6309
    • View Profile
Re: how can i make condition css style on cell ?
« Reply #1 on: October 05, 2020, 03:36:47 pm »
I see a color picker in your screenshot.

You can assign background color to a selected cell by this code.
 
Code: [Select]
grid.Selection().style('background-color', color )

Example of assigning colors to a cell with Color picker is here:

https://paramquery.com/pro/demos/import-xlsx