Page 1 of 1

how to count the number of the same character

Posted: Fri Jul 01, 2016 11:39 am
by Nikky_zhang
Hi ,

I am facing a problem without any solution. Can anyone help?

The problem is , I am trying to count the number of the same character appeared in a string.

For example,

<xsl:if test="contains(x1,x2)">

I want to express, if there are more than two X2 appeared in x2, then execute something. I don't know how.

anyone knows?

Re: how to count the number of the same character

Posted: Fri Jul 01, 2016 11:47 am
by Radu
Hi,

As the question is not directly related to Oxygen maybe you could consider using a specialized XSLT mailing list or writing on Stack Overflow.

Maybe this StackOverflow older post will help:

http://stackoverflow.com/questions/1458 ... ng-in-xslt

Regards,
Radu