How can I modify the style of a cel in a dataview?

3
How can I modify the colour of a cel in a dataview or which css should I use? Can I align the labels another way then the default?
asked
1 answers
8

The style of a cell in a dataview can be modified with the class and style properties on the particular cell. With the class property a class defined in the theme being used can be attached to the cell. With the style property css can be embedded in the form.

The background-color of a cell can be changed with the css property 'background-color'. Example: to change the background color of a cell to red, the style property should be set to background-color: red or background-color: #f00.

The align of a label inside a cell can be changed with the css property 'text-align'. Example: to align a label inside a cell to the left, the style property should be set to text-align: left.

Multiple css properties should be seperated with a semicolon. Example: to have a red cell with left-aligned text, the style property of the cell would be background-color: #f00; text-align: left.

More css properties along with a description can be found here: http://www.w3schools.com/CSS/CSS_reference.asp.

answered