Logo 
Search:

Asp.net Forum

Ask Question   UnAnswered
Home » Forum » Asp.net       RSS Feeds

Changing Font Color Based on values retrieved from DB

  Asked By: Lamberta    Date: Jul 22    Category: Asp.net    Views: 1542
  

How can I get values from a database to show up in different colors?
(I'd like to have values in a table, say below 5 show in green,
between 5-7 show in yellow, and 8-10 show in red.)

Application:
I have an application where I report conditon ratings of various
infrastructure assets. These values come from a database that I
update in Access and then use an asp page to report the values.

Existing Code:
The following code is what I have now to display all in black (If
you give me the script, where do I place it in the following code - I
don't know anything about programming):


<!--webbot bot="DatabaseResultColumn" startspan
s-
columnnames="ID,ORGN,FACIDNR,PROJNBR,WONR,WOTITLE,TRKIND,WOSTATUS,CRED
ATE,MORE INFO"
s-column="PROJNBR" b-tableformat="TRUE" b-hasHTML="FALSE"
clientside
local_preview="<font size="-
1">&lt;&lt;</font>PROJNBR<font size="-
1">&gt;&gt;</font>"
preview="<font size="-
1">&lt;&lt;</font>PROJNBR<font size="-
1">&gt;&gt;</font>" --><%=FP_FieldVal
(fp_rs,"PROJNBR")%><!--webbot
bot="DatabaseResultColumn" i-CheckSum="9646" endspan -->

Share: 

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on Changing Font Color Based on values retrieved from DB Or get search suggestion and latest updates.




Tagged: