473,503 Members | 1,733 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Translate() doesn't work

Hi,

I am using the Translate() function in one of the .XSLT file to remove the
spaces, like this:
<xsl:for-each select=".//Illustration">
<xsl:value-of select="translate(./@illusName, ' ', '')"/>
….

This works fine with command line msxsl and XML editors like XMLSpy.
However, if you use .NET's
XSLTransform.Transform() method to access the same .xslt file, it doesn't
remove the spaces.

I also tried the following workarounds, but it still doesn't work:
<xsl:element name="{translate(./@illusName, ' ', '')}">
<xsl:value-of select="translate(./@illusName, ' ', '')"/>

Is this a known problem with .NET?
Plz help!
Feb 23 '07 #1
1 2541
Gaurav wrote:
This works fine with command line msxsl and XML editors like XMLSpy.
However, if you use .NET's
XSLTransform.Transform() method to access the same .xslt file, it doesn't
remove the spaces.

I also tried the following workarounds, but it still doesn't work:
<xsl:element name="{translate(./@illusName, ' ', '')}">
<xsl:value-of select="translate(./@illusName, ' ', '')"/>

Is this a known problem with .NET?
I can't reproduce the problem with a simple example and .NET 1.1. Can
you post a minimal XML input document, minimal XSLT stylesheet and your
..NET code that runs the transformation?
--

Martin Honnen --- MVP XML
http://JavaScript.FAQTs.com/
Feb 23 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
4942
by: +Vice | last post by:
Can anyone help me translate this statement from using the legacy outer joins to the SQL-92 standards? Select CA.* From Customer C, Shipper S, Customer_Order CO, Cust_Address CA Where...
1
11151
by: Joe | last post by:
Hi all Is there a TSQL function like Oracle's Translate function? Where: Translate('13,000 Miles','abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ, ',' ') would return '13000'? I'm...
4
2135
by: Gadrin77 | last post by:
I have data that looks like <Root> <Main Value="Line1|Line2.|Line3|Line4.|Line5"/> </Root> I'm using Translate(@Value, "|.", ",")
1
1934
by: Martin | last post by:
Shown below is the body of a web page I'm developing. When it loads, a socket connection is established back to a socket that's on my server. I can then send a message from the server and it will...
6
1666
by: VBTricks.de.vu Webmaster | last post by:
Hello, in VB6 I used to translate my application by setting the tag-property of all controls, menu-entries... to a number which has been linked to a string (array). Then I went through all...
6
2732
by: bobueland | last post by:
The module string has a function called translate. I tried to find the source code for that function. In: C:\Python24\Lib there is one file called string.py I open it and it says
1
9369
by: peterbe | last post by:
This has always worked fine for me. Peter fine Now if I do it with a unicode string: Traceback (most recent call last): File "<stdin>", line 1, in ? File "/usr/lib/python2.4/string.py", line...
9
3083
bvdet
by: bvdet | last post by:
I have done some more work on a simple class I wrote to calculate a global coordinate in 3D given a local coordinate: ## Basis3D.py Version 1.02 (module macrolib.Basis3D) ## Copyright (c) 2006...
3
649
by: muybluie | last post by:
Hello All, I am trying something so simple, I have no idea why it doesn't work! create table test1 (c1 VARCHAR(16)); insert into test1 values( '12154846' ); select translate(c1, '5', 'A')...
0
7203
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7281
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7334
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5579
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4675
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3156
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1514
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
737
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
383
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.