Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Sherry Ann Hernandez 320 posts 344 karma points
    Aug 23, 2011 @ 14:28
    Sherry Ann Hernandez
    0

    How do I get the values of Datatype Grid in xslt?

    I need to display it but I can't see any sample in the codeplex documentation.

    Any help?

    Thanks,

    Sherry

  • psiho 101 posts 96 karma points
    Dec 06, 2011 @ 01:48
    psiho
    0

    It must be late, or I'm going crazy. i've done hundreds of XSLT macros but simply cannot make Data Grid to work! i'm also looking for some examples.

    My datatype is named "propertyprices" so Datagrid creates XML like:

    <propertyprices>
      <items>
        <item id="1">
          <propertypriceperiod nodename="PropertyPricePeriod" nodetype="-88">1.1. - 30.4.</propertypriceperiod>
          <propertypriceperday nodename="PropertyPricePerDay" nodetype="-51">100</propertypriceperday>
        </item>
      </items>
    </propertyprices> 

    I expected this to work:

     

    <xsl:for-each select="$currentPage/propertyprices/items/*">
      <xsl:value-of select="./propertypriceperiod"/>
    </xsl:for-each>

    but it does not :(

    I cannot even get anything with:

    <xsl:copy-of select="$currentPage/propertyprices/*"/>

     

  • psiho 101 posts 96 karma points
    Dec 06, 2011 @ 17:04
    psiho
    0

    after good night sleep I solved this for me. Problem was that xsl:copy-of was returning all small cases while actual XML was (not capitalization):

    <propertyPrices>
     
    <items>
       
    <itemid="1">
         
    <PropertyPricePeriodnodename="PropertyPricePeriod"nodetype="-88">1.1. - 30.4.</propertypriceperiod>
         
    <PropertyPricePerdaynodename="PropertyPricePerDay"nodetype="-51">100</propertypriceperday>
       
    </item>
     
    </items>
    </propertyPrices>

    Of course, XPath is case sensitive, but I'm really surprised xsl:copy-of returns all small caps!? I cannot remember ever having this problem and was allways using copy-of in my debugging to explore current page xml.

Please Sign in or register to post replies

Write your reply to:

Draft