• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

help on xsl iteration

 
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all

I have 2 strings string1 and string2 which are both comma delimted. What I wasnt to do is tokenize xsl helper on both strings and then cycle round them.

i.e. I want to do something with the 1st value in both lists then the 2nd value in both lists and so on.

ultimately I want something like a foreach but have access to the current index value in both lists

How can i do this?

Thanks
 
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
A recursive template. I don't have my XSLT reference at the moment but it would look something like this:

Obviously not checked for correctness.
 
nandkishor rao
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think this is something whcih I want but its partial,
Once you are getting the tokens,then for each of the tokens
I need loop. Its like for each token I again have some strings
which I have to loop around.
So I need two loops one for the tokens and other one for each token.
 
Bartender
Posts: 2856
10
Firefox Browser Fedora Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"nandkishor ra " please check your private messages.

Thanks.
 
reply
    Bookmark Topic Watch Topic
  • New Topic