Subject: Re: [xsl] Changing row colors using variables From: "Thomas B. Passin" <tpassin@xxxxxxxxxxxx> Date: Thu, 8 Nov 2001 10:58:13 -0500 |
[Steve Kuntz] > I know that I can't assign a variable like that...and the logic for the > colors is more complex than every other row. My table will be sorted based > on a certain attribute, and I want all like attributes colored the same. > Sounds like maybe there is no way to do this. > I assume that you don't know what values those attributes may have, just that some will be different. If you knew what they would be, you could just code the values into the stylesheet or (better) use an external xml file defining which colors to use. You ought to be able to do what you ask for by creating a variable that contains the first occurrence of an element with each value of that attribute - a unique list, in other words. Then when you find that attribute, find the position of its parent element in that list and use that position to select the color. This will let you color the same values with the same color. to specify the actual colors to apply you may want to use an external xml file, called in using document() See the FAQs to find out how to create a unique list. Cheers, Tom P XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Changing row colors using, David Carlisle | Thread | [xsl] XSL Sorting Question - Meunch, Magick, Brian |
RE: [xsl] Q on ISO TimeDate convert, Mark Nahabedian | Date | Re: [xsl] reliability of MSXML, Trevor Nash |
Month |