AnsweredAssumed Answered

Pick Nth occurrence using regexp

Question asked by Kranthi Paidi on Feb 5, 2016
Latest reply on Feb 5, 2016 by Salvador Camacho Reyes

hi

 

I have a webpage which returns a set of URLs for each asynchronous frame. These URLs have a pattern shown below:

https://#####--##--######.visual.force.com/servlet/servlet.Integration?lid=066q00000008bUg

 

There are a total of 12 such URLs and action on any of the URL needs to be correlated with the lid value.

 

The following regexp picks the first one of this.

 

(?<=\Q<form  action="https://#####--##--######.visual.force.com/servlet/servlet.Integration?lid=\E).*?(?=&)

 

However, when I tried to pick an Nth value (for example 3rd value using {3}) I get no match.

 

Is there a specific syantax I am missing here? Thanks in advance

 

Thanks,

Kranthi

Outcomes