SharePoint – How to Debug XSL Variables

Sometimes you need to build some conditional tests in you SharePoint Forms using XSL.

All of that is not a problem, but degugging a variable is a different story.

<xsl:variable name=”LOOKUP_ID”><xsl:value-of select=”@Account_x003a_ID” disable-output-escaping=”no”/></xsl:variable>

<xsl:copy-of select=”$LOOKUP_ID” />

<!– display the value of the variable used in test below on the existence of CRM account for the current value—>

Using the <xsl:copy-of method is very useful to check the content of the variable and display it in a form at anytime.

Tip : look at the different syntax select=”$LOOKUP_ID” starts with a ‘$’ instead of a @

Enjoy !

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: