XSL help....

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello Guys,

I am trying to render an Xml dataset into HTML using XSLT.
When I am loading the XSLT file into transform object to
render it. Here is the code snippet:

<!--
XslTransform transCart = new XslTransform();
transCart.Load(Server.MapPath("1.xslt"));
showCart.Document = cartFromSession;
showCart.Transform = transCart;
-->

showCart is my xml control and cartFromSession is my
XmlDocument.

When I run the application, I get an error saying that the
The path is too long after being fully qualified. Make
sure path is less than 260 characters.

Stack Trace:
[PathTooLongException: The path is too long after being
fully qualified. Make sure path is less than 260
characters.]
System.IO.Path.nGetFullPathHelper(String path, Char[]
invalidPathChars, Char[] whitespaceChars, Char
directorySeparator, Char altDirectorySeparator, Char
volumeSeparator, Boolean fullCheck, String& newPath) +0
System.IO.Path.GetFullPathInternal(String path) +165
System.IO.Path.GetFullPath(String path) +19
System.Xml.XmlResolver.ResolveUri(Uri baseUri, String
relativeUri) +599
System.Xml.XmlTextReader..ctor(String url, XmlNameTable
nt) +91
System.Xml.XmlDocument.Load(String filename) +52
vivek.checkout.Page_Load(Object sender, EventArgs e)
+755
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731


Can anyone help me out with this?

Thanks a lot!
 
Yes, I did try printing out the mapped path using
response.write but the path was 39 characters.

Surprisingly, I am able to render the same Xml dataset
using the same XSLT in one of my webforms earlier. Can
anyone please help me out.

Here is the code snippet


<!--
XslTransform transCart = new XslTransform();
transCart.Load(Server.MapPath("1.xslt"));
showCart.Document = cartFromSession;
showCart.Transform = transCart;
-->

showCart is my xml control and cartFromSession is my
XmlDocument.

When I run the application, I get an error saying that
the
The path is too long after being fully qualified. Make
sure path is less than 260 characters.

Stack Trace:
[PathTooLongException: The path is too long after being
fully qualified. Make sure path is less than 260
characters.]
System.IO.Path.nGetFullPathHelper(String path, Char[]
invalidPathChars, Char[] whitespaceChars, Char
directorySeparator, Char altDirectorySeparator, Char
volumeSeparator, Boolean fullCheck, String& newPath) +0
System.IO.Path.GetFullPathInternal(String path) +165
System.IO.Path.GetFullPath(String path) +19
System.Xml.XmlResolver.ResolveUri(Uri baseUri, String
relativeUri) +599
System.Xml.XmlTextReader..ctor(String url,
XmlNameTable
nt) +91
System.Xml.XmlDocument.Load(String filename) +52
vivek.checkout.Page_Load(Object sender, EventArgs e)
+755
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731

-----Original Message-----
do you try what I said to try, in my reply to your post from yesterday?


Hello Guys,

I am trying to render an Xml dataset into HTML using XSLT.
When I am loading the XSLT file into transform object to
render it. Here is the code snippet:

<!--
XslTransform transCart = new XslTransform();
transCart.Load(Server.MapPath("1.xslt"));
showCart.Document = cartFromSession;
showCart.Transform = transCart;
-->

showCart is my xml control and cartFromSession is my
XmlDocument.

When I run the application, I get an error saying that the
The path is too long after being fully qualified. Make
sure path is less than 260 characters.

Stack Trace:
[PathTooLongException: The path is too long after being
fully qualified. Make sure path is less than 260
characters.]
System.IO.Path.nGetFullPathHelper(String path, Char []
invalidPathChars, Char[] whitespaceChars, Char
directorySeparator, Char altDirectorySeparator, Char
volumeSeparator, Boolean fullCheck, String& newPath) +0
System.IO.Path.GetFullPathInternal(String path) +165
System.IO.Path.GetFullPath(String path) +19
System.Xml.XmlResolver.ResolveUri(Uri baseUri, String
relativeUri) +599
System.Xml.XmlTextReader..ctor(String url, XmlNameTable
nt) +91
System.Xml.XmlDocument.Load(String filename) +52
vivek.checkout.Page_Load(Object sender, EventArgs e)
+755
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731


Can anyone help me out with this?

Thanks a lot!


.
 
In article said:
Hello Guys,

I am trying to render an Xml dataset into HTML using XSLT.
When I am loading the XSLT file into transform object to
render it. Here is the code snippet:

<!--
XslTransform transCart = new XslTransform();
transCart.Load(Server.MapPath("1.xslt"));
showCart.Document = cartFromSession;
showCart.Transform = transCart;
-->

showCart is my xml control and cartFromSession is my
XmlDocument.

When I run the application, I get an error saying that the
The path is too long after being fully qualified. Make
sure path is less than 260 characters.

I'm just guessing, but it sounds like you've got a namespace declaration
running amok here. I don't think the code snippet above reveals
anything relevant, it's the xslt (and perhaps xml) source that is
probably causing the problem.
 
Back
Top