Micro Focus QTP (UFT) Forums
QTP Scripts - 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 Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: QTP Scripts (/Thread-QTP-Scripts)



QTP Scripts - loki.kl - 04-03-2009

HI All,

Im new to QTP, could any one write sample script for the following form

-- Student Admission Form

Student id --- Textbox
Student Name -- Textbox
Gender --- Dropdown box (Male , Female )
DOB -- Calendar control
Address -- Text Area
and following
Save, Update, delete and Cancel Button

Thanks in Advance.Smile


RE: QTP Scripts - nandu - 04-07-2009

Student id --- Textbox
Student Name -- Textbox
Gender --- Dropdown box (Male , Female )
DOB -- Calendar control
Address -- Text Area
and following
Save, Update, delete and Cancel Button

The following is the code if your form in a web page

Code:
Browser("..").page("studentform").webedit("StudentId").set "1"
Browser("..").page("studentform").webedit("studentname").set "nandu"
Browser("..").page("studentform").weblist("Gender").select "Female"
Browser("..").page("studentform").image("DOB").click
Browser("..").page("studentform").image("DOB")...set "09-09-09"
Browser("..").page("studentform").webedit("Address").set "city,town..."
Browser("..").page("studentform").webbutton("save").click