QTP Script

Ranked #10,393 in Computers & Electronics, #208,416 overall

Qtp script for connecting to database

Script for connecting to database in qtp.Here database i used is MS Access.

QTP Script for connecting to database

QTP Script

This post will give u steps(script)to connect to database using MS Access.

Option Explicit
Dim con,rs
Set con=createobject("adodb.connection")
Set rs=createobject("adodb.recordset")
con.provider="microsoft.jet.oledb.4.0"
con.open"d:\testdata.mdb"
rs.open"select*from emp",con
Do while not rs.eof
VbWindow("Form1").VbEdit("val1").Set rs.fields("v1")
VbWindow("Form1").VbEdit("val2").Set rs.fields("v2")
VbWindow("Form1").VbButton("ADD").Click
rs.movenext
Loop

Database we are using here is MS Access.before running this script create a table in MS Acess.

In the above script i used table called "emp" and column names as "v1" and "v2".

"d:\testdata.mdb" is path of the table which we created in MS Access.

Main use of this application is to use testdata of table(which is in database) in the application.

for connecting to SqlServer and Oracle

http://funandknowledge.blogspot.com/2008/03/qt.html

Data Driven testing

http://hubpages.com/_zpfb7rxec2a6/hub/descriptive-programming-for-data-driven-testing-using-notepad

Other Scripts

http://funandknowledge.blogspot.com

http://sqlqueriescollection.blogspot.com

http://moviessongslyrics.blogspot.com
Loading

QTP Scripts

QTP Scripts and Descriptive Programming in QTP

Script for connecting to database,D.P for yahoo login page,Data driven testing using excel sheet,timeout for message box.
QTP Scripts
by snig123456 | video info

8 ratings | 33,306 views
curated content from YouTube
check this blog for more qtp scripts.

http://funandknowledge.blogspot.com

http://sqlqueriescollection.blogspot.com

http://moviessongslyrics.blogspot.com

Great Stuff on eBay

Loading

New Guestbook

  • snigdha_123 Apr 10, 2008 @ 2:54 pm | delete
    Thanks Elizabeth .
  • ElizabethJeanAllen Apr 2, 2008 @ 5:20 pm | delete
    Nice lens.
    Great information

by

snigdha_123

Hello world. This is my bio. I can edit it later!

http://www.funandknowledge.blogspot.com/

Feeling creative? Create a Lens!