Latest QTP FAQS

July 15, 2008

1.What is File System Object?

File System is used to create file through scripting.

We can read, write and save data in txt file and use it after wards
during testing.

Here is example of creating txt file through FSO

Const ForReading = 1, ForWriting = 2
Dim fso, MyFile
Set fso = CreateObject( “Scripting. FileSystemObject “)
Set MyFile = fso.OpenTextFile( “c:testfile. txt”, ForWriting, True)
MyFile.WriteLine “Hello world!”
MyFile.WriteLine “The quick brown fox”
MyFile.Close
Set MyFile = fso.OpenTextFile( “c:testfile. txt”, ForReading)
ReadLineTextFile = MyFile.ReadLine ‘ Returns “Hello world!”

It will create testfile.txt and enter “This is a test” in that text
file.

You can later read that line “This is a test” from this file while
using

MyFile.ReadLine

We can save variables data during testing and then use that data in
future instances of testing and then delete that file.

2.Can we perform performance testing by qtp?

we can do the performance testing in QTP, which can be done only for
one user. We can do the performance testing using QTP by inserting
the start and end transactions for getting the response time of each
transaction with single user.

3.How can I execute PL/SQL stored procedure (with parameters)
thorough VBScript?
Here is the code:
conStr=”driver= sql
server;server= servername; database= test;uid= sa;pwd=sa”
Set cmdObj=createobject (“adodb.command” )
Set recObj=createobject (“adodb.recordse t”)
With cmdObj
.activeconnection= conStr
.commandtype= 4
.commandtext= “SP_Insert_ EMP” – SridharName
.parameters. refresh
.parameters( 1).value= 22 – Parameter values that i am passing to SP
.parameters( 2).value= “PULSE TECHNOLOGIES” -
.parameters( 3).value= “QA” -
.parameters( 4).value= 7777 -
.parameters( 5).value= NULL -
.execute
End with

Entry Filed under: QTP. Tags: .

4 Comments Add your own

  • 1. vamshi  |  July 16, 2008 at 3:42 pm

    Hi Sridahr

    I need help in genarating the HTML format of report.

    When the QTP runs it saves his report in HTML in log folder.

    But I am unable to insert some information in the report..

    if u know any idea can you mail me…

    Vamshi

    Reply
  • 2. Rakesh  |  September 24, 2008 at 10:05 am

    hi Shri
    please tell me all steps to use text check point in script with 1 one simple example.

    Thanks
    Rakesh

    Reply
  • 3. Swarupa  |  December 22, 2008 at 4:15 pm

    Hi,

    Can any body tell me the link where we can get latest information abt the daily interviews and walk-ins in MNC’s.Please forward the link to swaruparani_suryavanshi@yahoo.co.in

    Regards
    Swarupa

    Reply
  • 4. Srinivasulu  |  February 14, 2009 at 7:28 am

    Hi,
    Sridhar this is srinivasulu,i saw your answers on qtp i am so impressive.

    Colud you please give me some idea on how we can do database testing by using Qtp.plese send me the script with example.

    Thanks&Regards,
    Srinivas

    Reply

Leave a Comment

Required

Required, hidden

Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <pre> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Trackback this post  |  Subscribe to the comments via RSS Feed


Blog Stats

Categories

Recent Posts

 

July 2008
M T W T F S S
« Mar   Aug »
 123456
78910111213
14151617181920
21222324252627
28293031  

Archives

Blogroll

Meta