Solved

How to call another vbscript function within msxsl script ??

Posted on 2003-11-25
5
1,006 Views
Last Modified: 2012-05-04
Hi,

I have embedded vbscript inside xsl, till now i was calling vbscript function from xsl and it was working fine.

How can i call another vbscript function from that embedded script ?

I tried to call a function using prefix inside vbscript still didn't worked and it give me error like "a semi colon character is expected in line no. xyz "

Here is that line : <msxsl:script language="VBScript" implements-prefix="myPrefix">

Can somone please throw some light on this issue.

Thanks in the anticipation that i will get some hint to solve this.

Regards,
Dipesh
0
Comment
Question by:DipehKhakhkhar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 26

Expert Comment

by:rdcpro
ID: 9822056
If you're inside the script block executing functionA, and you want to call functionB, you don't need to specify prefixes.  That's only when you call a function from XPath.  You'll have to post a bit more code for us to help.

Regards,
Mike Sharp
0
 
LVL 1

Author Comment

by:DipehKhakhkhar
ID: 9822240
Hi Mike,

Thanks for replying immediately.

Exactly i did that only and whenever i was making call from xsl part it was working. Then i checked my vbscript which was inside <xsl:msxsl> element and i found that it was conidering characters like "&",  "<" and ">" as xsl/xml specific characters. Because of this i was getting errors and i changed them respectively to &amp; &lt; and &gt; and it then worked for me.

Since my output is text only i thought, it will escape these characters but it does not.

But finally i got my solution.
Thanks for your reply.

Regards,
Dipesh
0
 
LVL 9

Expert Comment

by:sparkplug
ID: 9824003
A simpler solution for escaping character in script would be to use CDATA tags:

e.g.

<msxsl:script language="VBScript" implements-prefix="myPrefix">
<![CDATA[
    Function AddFullStop(s)
            AddFullStop=s & "."
    End Function
]]>
</msxsl:script>

>S'Plug<
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 11355891
Closed, 75 points refunded.

modulo
Community Support Moderator
Experts Exchange
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Client Need Led Us to RSS I recently had an investment company ask me how they might notify their constituents about their newsworthy publications.  Probably you would think "Facebook" or "Twitter" but this is an interesting client.  Their cons…
Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…

732 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question