Micro Focus QTP (UFT) Forums
Regular Expression - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Regular Expressions (https://www.learnqtp.com/forums/Forum-UFT-QTP-Regular-Expressions)
+--- Thread: Regular Expression (/Thread-Regular-Expression--6191)



Regular Expression - samverma - 03-29-2012

Hi All,
I recently started working on QTP. I am trying to implement descriptive programming and regular expression together.

Code:
Browser("abcd").Page("abcd").WebEdit("html tag:=INPUT","Html id:=txt+","Name:=txt+")

I checked the Object property, html id is txtname or txtpassword etc, few other too starting with 'txt'

however, I am getting run time error with "txt+" , can anyone please help me with the error.

Thanks,

Sam


RE: Regular Expression - Ankesh - 03-29-2012

Code:
strHTMLID="txt.*"
Browser("abcd").Page("abcd").WebEdit("html tag:=INPUT","Html id:="&strHTMLID,"Name:=txt+")


Try the above code.

Regards,
Ankesh


RE: Regular Expression - samverma - 03-29-2012

Thanks Ankesh, I'll try it soon and let you know.


RE: Regular Expression - samverma - 03-31-2012

Hi Ankesh,
can you please help me again.
I tried the above code, however I am still getting error. It seems strHTMLID="txt.*" is not refrenced as "txtName" or "txtlogin"

Can you please suggest further.

Thanks

Sam