Skip to main content
Sympraxis Consulting

Demos

Go Search
Home
Services
Clients
About
Demos
Contact
  

Sympraxis Consulting > Demos > Demo Pages > DVWPCalcHTMLColumn

 Sales Opportunities

TitlePotential ValueColorColorHTMLConverted ColorHTML
 

 DVWP Calculated HTML Column

Thie page shows a technique developed by Christophe Humbert which he calls the HTML Calculated Column. Christophe asked me some questions about how to go about "unescaping" HTML in a Data View Web Part (DVWP), and this is the page which resulted.

The ColorHTML column is a calculated column which contains the formula:
="<span style='background-color:black;font-size:24px;'><span style='padding:-10px;color:"&IF(Color="Green","green;'>✹","gray;'>✹")&"</span><span style='padding:-10px;color:"&IF(Color="Amber","RGB(255, 191, 0);'>✹","gray;'>✹")&"</span><span style='padding:-10px;color:"&IF(Color="Red","red;'>✹","gray;'>✹")&"</span></span>"

If you'd like to see more items with different values, you can create new items in the Sales Opportunities list.

  • You can see the XSL for the DVWP here.