Solved

Conditional formatting partially working

Posted on 2013-01-07
5
362 Views
Last Modified: 2013-01-13
Hi All,

I have a web part page with a list and used conditional formatting to changed the color and font-weight.

In SP designer 2010 both color and bold font render correctly but in the browser, the bold shows but the color does not.

Any ideas why that is?

Here's the xslt:

	<xsl:attribute name="style">
			<xsl:if test="normalize-space($thisNode/@Status) = 'Complete'" ddwrt:cf_explicit="1" xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime">color:Green; font-weight: bold;</xsl:if>
			
			<xsl:if test="$Collapse">display:none;</xsl:if>
		</xsl:attribute>

Open in new window

0
Comment
Question by:Isaac
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
5 Comments
 
LVL 5

Author Comment

by:Isaac
ID: 38752758
This is really weird.  The background-color works too.  It's just the showing the color of the text.
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 38752804
Just a quick guess.  color names are all lowercase change Green to green and maybe we get lucky.

Cd&
0
 
LVL 5

Author Comment

by:Isaac
ID: 38752883
No luck there!
0
 
LVL 5

Accepted Solution

by:
Isaac earned 0 total points
ID: 38752927
According to this blog, it can't be done.
http://www.jrjlee.com/2011/06/conditional-formatting-of-list-views.html

The problem is that the color is getting overriden by ms-vb2.
0
 
LVL 5

Author Closing Comment

by:Isaac
ID: 38771560
Found it can't be done unless I use jQuery or something or if I apply conditioning to each column instead of the row.
0

Featured Post

Learn by Doing. Anytime. Anywhere.

Do you like to learn by doing?
Our labs and exercises give you the chance to do just that: Learn by performing actions on real environments.

Hands-on, scenario-based labs give you experience on real environments provided by us so you don't have to worry about breaking anything.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
I thought I'd write this up for anyone who has a request to create an anonymous whistle-blower-type submission form created using SharePoint 2010 (this would probably work the same for 2013). It's not 100% fool-proof but it's as close as you can get…
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
In this tutorial viewers will learn how to customize the background color and font color of highlighted text using the ::selection element in CSS Begin by defining the selected text as an element in CSS by typing "::selection": Style the ::selection…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question