Prepare for your Next Interview
|
Welcome to the Geeks Talk forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
This is a discussion on Import From Database within the QTP forums, part of the Software Testing category; How to import data from database to datatable? For example: I have a Username and password fields. For Username, data should be get from the Excel sheet For Password, data ...
|
|||||||
|
|||
|
Import From Database
How to import data from database to datatable?
For example: I have a Username and password fields. For Username, data should be get from the Excel sheet For Password, data should be get from the database. How to the write the script? |
| Sponsored Links |
|
|||
|
Re: Import From Database
the below script will use for parameterizing from Excel sheet....
On error resume next Set objExcel = CreateObject("Excel.Application") strPathExcel = "C:\Documents and Settings\Madhu Sudhan\Desktop\nanda" objExcel.Workbooks.open strPathExcel Set objSheet = objExcel.ActiveWorkbook.Worksheets(1) For i=1 to 5 user= Trim(objsheet.cells(i,1).value) psd = Trim(objsheet.cells(i,2).value) systemutil.Run "C:\Program Files\Mercury Interactive\QuickTest Professional\samples\flight\app\flight4a.exe" dialog("Login").WinEdit("Agent Name:").Set user dialog("Login").WinEdit("Password:").SetSecure crypt.Encrypt(psd) dialog("Login").WinButton("OK").Click If dialog("Login").Dialog("Flight Reservations").Exist Then dialog("Login").Dialog("Flight Reservations").WinButton("OK").Click dialog("Login").WinButton("Cancel").Click else window("Flight Reservation").Activate window("Flight Reservation").Close End If Next objExcel.Application.Quit Set objExcel=Nothing WIth Ragrds.. Nanda.. |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How can I export / import the tables from one database to another | Geek_Guest | Oracle | 2 | 07-30-2007 09:22 AM |
| What is need to import java.awt.event.* | Geek_Guest | Java | 1 | 05-29-2007 05:29 AM |
| Import sources from different databases | josephreddy | Data Warehousing | 1 | 04-20-2007 03:03 AM |
| Microsoft CRM : 5 ways to import data | Jim.Anderson | Microsoft CRM | 0 | 09-27-2006 07:39 AM |
| WebSphere V5.0 : Import and export | Lokesh M | Web Tools | 0 | 05-27-2006 07:26 AM |