Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How To write script in QTP For Field Validation Example:
password Field is accepting A range 8-20 characters
only.How to write script?

Answer Posted / ganesh kumar

Dim strTextValue

strtextValue = Browser("Browser").Pge("Page").Frame
("Frame").webEdit("Password").GetRoProperty("value")
If strTextValue <8 Then
Reporter.ReportEvent micFail,"Check for the Feild
validation","The Feild is accepting Lesserthan
lowerBoundary value"

ElseIf strTextValue>20 Then
Reporter.ReportEvent micFail,"Check for the Feild
validation","The Feild is accepting Greater than
UpperBoundary value"

Else
Reporter.ReportEvent micFail,"Check for the Feild
validation","The Feild is not accepting lesserthan or
Greater than the Boundary value"

EndIF

Is This Answer Correct ?    14 Yes 12 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

In the website, the protocol has been changed http: to https what you will do? Tell me your approach?

969


Can we run multiple QTP scripts one after the other without manual intervention? How?

994


i want information about API testing and i want info like how process can be done in company? i want added info like coding ,debugging, desing in c.v ? what should add in c.v for eg banking domin? pls any answer my question?

2017


You will receive the mail in your outlook from client at night time to go ahead for the execution. Based on the mail you need to trigger the batch run. What is the QTP Code for this?

1846


what is the latest version of QTP? Main difference between 9.2 and 10 version

2049


Is there anyway to automatically update the Datasource name in Database Checkpoints object when we migrate tests to a new release?

3802


Please help me by providing the License key for QTP 9.2, at guru_aarya@yahoo.co.in Best Regards Gururaj.B

3311


Can you list some technologies that support qtp?

910


Output values? i want a practical example

1694


Write a script to verify font style and color of a windows object using descriptive programming

1319


how to use the regular expression for the below code-- swf("application name").swftreeview ("Treename").select"Medication;Pharmacy:56" There is a tree view window of the folder's ie Medication- >Pharmacy(sub folder)with 56 as count of records...The records can be different or if no records present in the specific folder..then it show "Paharmacy:-no records".Whe i record at the first time .....and try to rerun the same script with different records count say "pharmacy:800"..qtp is not regnizing it...therefore i want to user regular expression..but donot now how to use it and where to use...i have tried.... swf("application name").swftreeview ("Treename").select"Medication;Pharmacy:\*"..but it s of no use..plz help..me

2874


QTP script is not working on other's machine..

1927


Can we write winrunner language i.e TSL in QTP tool?

1930


how do u manipulating INI, DLL and / or registry files in support of your test environment? actually what do u mean by INI and DLL or registry files. plzzz its urgent do answer

1942


What are the different types of recording modes?

960