I don't think you have tried "all the suggestions", because the first one was to read help about "regular expression syntax", and you didn't do it. The way you use RE is completely wrong. If you would look in the help there is an example on the bottom of a page. Or look here http://www.devguru.com/technologies/vbscript/quickref/regexp.html
On Mon, Apr 27, 2009 at 12:26 PM, eve <[email protected]> wrote: > > Thank you for all the suggestions, but I am still having problems. I > tried everything posted here, and I am also doing something like this: > > if("It is not possible to release the item \w*\.prt because it is > locked\. It must first be unlocked\." = "It is not possible to release > the item platform\.prt because it is locked\. It must first be unlocked > \.") then > print ("true") > else print("false") > end if > > Still returning false. What am I doing wrong? > > On Apr 26, 2:46 pm, Srinivas Pavuluru <[email protected]> wrote: > > For Regular expression in QTP we can use ".*" > > > > "It is not possible to release the item .*.prt because it is > > locked.* It must first be unlocked.*" > > > > Thanks > > Srinivas P > > > > On Sat, Apr 25, 2009 at 7:47 AM, PBMax <[email protected]> wrote: > > > > > The easiest way is to do the following. It will allow any characters > > > besides newline for the part name. > > > > > "It is not possible to release the item .+\.prt because it is > > > locked\. It must first be unlocked\." > > > > > On Apr 24, 4:49 pm, eve <[email protected]> wrote: > > > > I have a string: > > > > > > "It is not possible to release the item platform.prt because it is > > > > locked. It must first be unlocked." > > > > > > I want to turn it into regular expression and remove platform.prt, > > > > because it can be any other part name. How do I do that? In java I > > > > can just do * instead of platform.prt and it will work. I see thats > > > > now how VB works. > > > > > > Thank you in advance for help. > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google "QTP - HP Quick Test Professional - Automated Software Testing" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/MercuryQTP?hl=en -~----------~----~----~----~------~----~------~--~---
