hi in QTP 8.2 in the edit box has text like "raju want
married" . i want to check "want" is their in the text
or not ?

Answer Posted / srinath

One method is


a="Raju want to marry"
b="want"

if instr(1,a,b) then
msgbox("Exists")
else
msgbox("Does not exists")
end if

another method is
use regular expression. this is a bit lengthy

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

when I try to run below script in QTP "totalPages" value is 2. But i am getting error message (Type mismatch: 'totalPages' Line (): "For i=1 to totalPages".) totalPages=Browser("Name:=User").Page("Title:=User").WebElem ent("innertext:=of.*").GetROProperty("InnerText") msgbox totalPages For i=1 to totalPages rnum=Browser("Name:=User").Page("Title:=User").WebTa ble("column names:=User Name;ID;Last Name;First Name").GetRowWithCellText("store4") If rnum>0 Then r=rnum Exit for End If Browser("Name:=User").Page("Title:=User").WebElement ("html tag:=A","x:=471").Click MsgBox "Exit" Next

3279


How many tabs are available in debug viewer pane?

649


any body can you help me what is the script to automate an comand promt

1978


What are test settings and global settings?

579


I would like to directly import XL file and work on that XL file directly in QTp script in that XL sheet need to allocate workbench,XL sheet and generate two bar graphs automatically how to do that? plz let me know any answers?

1567






Explain the concept of how quicktest professional (qtp) identifies object?

577


hi can any body give me a script for creating a modularity or keyword driven framework..i am working as a qtp tester for 2 months but still i am not exposed to framework in my company

1428


how do you parameterize search button from the website? the page is a single winobject and i have made a virtual object button of search button but search box can't be converted into a winedit and if we try to convert it into winedit the value we enter in a searchbox appears as numbers in the script so we arent able to parameterize.help!!!

1737


How to create a standard checkpoint ?

557


www.icici.com ,after this.. home page wll came, in this page what r the items we r going to test for manual and what are items we r going to test for QTP... explian clearly with example

1728


write the vb script for call to new action in qtp?

1861


Explain how qtp identifies objects?

568


Explain qtp(quick test professional)?

583


What is the synchronization point in qtp?

563


What are main panes available in qtp test browser?

539