Search code examples
extjs4

changing the background color of each cell in the form in extjs


In grid for changing the background color of a cell we have code something like this:

   .later .x-grid-cell {
         background-color: #FFB0C4 !important;     
   } 
   .now .x-grid-cell {
         background-color: #5491BD !important;     
   }

Is there anything like this for changing the background color of each cell in the form?


Solution

  • I think that the property is

    .value .x-form-field{
        background : red;
    }
    

    This must change the background of each field if you change the cls to value.

    If you want to change separately each field you must add the fieldStyle property

    fieldStyle: 'background: blue;'
    

    In this fiddle there is an example http://jsfiddle.net/lisssb/Ln6PT/4/

    I hope this help