Copied to clipboard

Flag this post as spam?

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


  • Anthony Candaele 1197 posts 2049 karma points
    Jan 11, 2011 @ 09:47
    Anthony Candaele
    0

    system.OverflowException in newsList.xslt

    Hi,

    I download the Business Website Starter Pack 1.4

    I don't know if it is me who badly copied the xslt code from newsList.xslt, but when I try to save newslist.xslt I get a system.OverflowException:

    System.OverflowException: Value was either too large or too small for an Int32.
    at System.Convert.ToInt32(Double value)

    Anyone had the same problem?

    greetings,

    Anthony Candaele
    Belgium

     

  • Kim Andersen 1447 posts 2196 karma points MVP
    Jan 11, 2011 @ 10:18
    Kim Andersen
    0

    Hi Anthony.

    Can you provide us with the code that fails? Line number etc.

    /Kim A

  • lufutu 7 posts 27 karma points
    Jun 03, 2011 @ 11:27
    lufutu
    0

    I think becasu you not publish any content in News

    Let's publish it or edit your xslt

    In line 172 marco loads feature news and if you have not any news it will error

     

        <div class="main_news_item">
          <h3>
            <a title="{$featuredItem/@nodeName}" href="{umbraco.library:NiceUrl($featuredItem/@id)}">
              <xsl:value-of select="$featuredItem/pageHeading"/>
            </a>
          </h3>
          <p class="news_date"><xsl:value-of select="umbraco.library:FormatDateTime($featuredItem/newsDate, 'd MMMM, yyyy')"/></p>
          <p><xsl:value-of select="umbraco.library:ReplaceLineBreaks($featuredItem/newsSummary)" disable-output-escaping="yes" />...</p>
          <p><a title="{$featuredItem/@nodeName}" href="{umbraco.library:NiceUrl($featuredItem/@id)}">Read full story »</a></p>
        </div>


    let's check if $featuredItem != null

        <xsl:if test="$featuredItem != null">
        <div class="main_news_item">
          <h3>
            <a title="{$featuredItem/@nodeName}" href="{umbraco.library:NiceUrl($featuredItem/@id)}">
              <xsl:value-of select="$featuredItem/pageHeading"/>
            </a>
          </h3>
          <p class="news_date"><xsl:value-of select="umbraco.library:FormatDateTime($featuredItem/newsDate, 'd MMMM, yyyy')"/></p>
          <p><xsl:value-of select="umbraco.library:ReplaceLineBreaks($featuredItem/newsSummary)" disable-output-escaping="yes" />...</p>
          <p><a title="{$featuredItem/@nodeName}" href="{umbraco.library:NiceUrl($featuredItem/@id)}">Read full story »</a></p>
        </div>
        </xsl:if>

    It fixed !

    Good luck

Please Sign in or register to post replies

Write your reply to:

Draft