<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<link rel="stylesheet" type="text/css" href="stile1.css">
</head>
<body>
<%
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open("Provider = Microsoft.Jet.OLEDB.4.0; Data Source = c:/inetpub/test/database.mdb")
Set objRs = Server.CreateObject("ADODB.Recordset")
set objRs = objConn.Execute("SELECT * from Email")
Do while NOT objRs.EOF
oggetto = objRs("Oggetto")
' ti servono gli stili CSS che qui ho nominato come stile1, stile2, stile3 e default...
' oggetto nell'esempio l'ho paragonato a pippo, topolino, pluto... te metti il valore a te opportuno.
if oggetto = "I: prova" then
style = "stile1"
elseIf oggetto = "I: Possibilita' di laurearsi da 3 a 24 mesi" then
style = "stile2"
elseIf oggetto = "I: link x software backup win" then
style = "stile3"
else
style = "default"
end if
response.write "<div class="" & stile & "">OGGETTO =" & oggetto & "</div>"
objRs.Movenext
Loop
objRs.Close
Set objRs = Nothing
objConn.Close
Set objConn = Nothing
%>
</body>
</html>