Use .* for regularexpressions
ex:
browser("name:=yahoo.*").page("title:=yahoo.*").webedit("name:=usern.*).set "Rajaputra"
Use .* for regularexpressions
ex:
browser("name:=yahoo.*").page("title:=yahoo.*").webedit("name:=usern.*).set "Rajaputra"
__________________
Thanks & Regards!!
RAJAPUTRA
Hai friend,
open qtp and paste this in expert view, so that you can have basic idea regarding regular expressions
try this
function regexptest(patrn, strng)
dim regex, match, matches ' create variable.
Set regex = new regexp ' create a regular expression.
Regex.pattern = patrn ' set pattern.
Regex.ignorecase = true ' set case insensitivity.
Regex.global = true ' set global applicability.
Set matches = regex.execute(strng) ' execute search.
For each match in matches ' iterate matches collection.
Retstr = retstr & "match found at position " retstr = retstr & match.firstindex & ".
Match value is '" retstr = retstr & match.value & "'." & vbcrlf
next
regexptest = retstr
end function
msgbox(regexptest("is.", "is1 is2 is3 is4"))
thanks
deepa
Last edited by deepasree; 06-01-2009 at 07:25 AM.
can some one give a small code which explain all type of commonly used QTP frame work?