![]() |
![]() | ![]() | ![]() | Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - Re: Problem populating a >Thread Next - Re: Problem populating a Re: Problem populating aTo: NULL Date: 11/10/2006 7:43:00 AM Ok I understand your willing now. To use a variable you must write $ and the name back otherwise it's false Second point, in xslt you can't evaluate a string variable(or param) to make a xpath and the good news ;-) , your problem can be fixed by <xsl:value-of select="@*[name()=$Value]" /> -- My english is (very) rusted,please, don't hesitate to correct me Thanks "PlutoPlanet" wrote: > > I see a problem here > > <xsl:value-of select="$@Value" /> syntax is false > > I know that this systax is wrong > The only right syntax would be > <xsl:value-of select="@myValue" /> > to display the attribute's value (see "myValue" below) > <myexample myId="1" myValue="one" myOtherValue="uno" /> > > > <xsl:value-of select="$Value" /> correct > Therefore this also wrong, because it won't show the "myValue" > attribute of "myexample". > To get the attribute's value I need to put "@" as prefix in front of > the variable, right? > $Value represents a variable containing a string: "myValue". > If I just say <xsl:value-of select="$Value" /> then it would be the > same as <xsl:value-of select="myValue" />, which is not what I want, I > need <xsl:value-of select="@myValue" />, but by passing "myValue" as > variable. > > | ![]() | ![]() | ![]() |
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | |||||
|
