javascript functions with xslt

B

billsahiker

I have some javascript functions in an xslt file. Everything works and
produces the desired html, except when using the visual studio
debugger which gives the error "objects of type 'Script1' do not have
such a member" and references the line and column where the "this"
object is used, as in this.hourarray()

Any ideas on what the problem is?
 
M

Martin Honnen

I have some javascript functions in an xslt file. Everything works and
produces the desired html, except when using the visual studio
debugger which gives the error "objects of type 'Script1' do not have
such a member" and references the line and column where the "this"
object is used, as in this.hourarray()

Do you use JavaScript in the resulting HTML document of an XSLT
transformation or do you use JavaScript to implement extension functions
for your XSLT stylesheet? The latter is only possible if the XSLT
processor supports that and while both MSXML and .NET
XslTransform/XslCompiledTransform support script in stylesheet the
object models used differ.

Which version of Visual Studio do you use? Can you post a URL where the
problem occurs?
 
B

billsahiker

I use JavaScript to implement extension functions
in the XSLT stylesheet and am using VS 20005
 
M

Martin Honnen

I use JavaScript to implement extension functions
in the XSLT stylesheet and am using VS 20005

Can you show us the code that gives the error?
With Visual Studio 2005 the XSLT processor is
System.Xml.Xsl.XslCompiledTransform and you use JScript.NET as the
scripting language and furthermore you script the .NET framework APIs.
See <URL:http://msdn2.microsoft.com/en-us/library/wxaw5z5e(VS.80).aspx>
for the types used in the .NET framework when you pass an XPath/XSLT
type to an extension function.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top