dynamic stylesheet

G

Guest

I have a datalist being displayed as a table with 3 columns, the end user
would like to see the tables have different background colors based on model.

ex:
if model is chevy then the table is blue
if BMW then silver
if mazda then red

how can i accomplish this and can it be done?
VB.NET
 
E

Eliyahu Goldin

Do you mean setting different background colors for individual rows? Then
you should use ItemDataBound event in which you can change the background
color or CssStyle for the item (row) depending on item data.

Eliyahu
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top