How to call .vbs functions in QTP? plz Explain indetail

Answers were Sorted based on User's Feedback



How to call .vbs functions in QTP? plz Explain indetail..

Answer / kavs

to call function in QTP go to
test--->settings-->resorces-->add the .vbs file

correct me if am wrong.

Is This Answer Correct ?    4 Yes 0 No

How to call .vbs functions in QTP? plz Explain indetail..

Answer / bfakruddin

Above two answers are correct but they forgot to explain
about the differences of those?

1. Call .vbs file

Test Settings-->Resources-->+ button-->show the path of .vbs
file-->Click OK button

Click the "Check Syntax button"

It is available for all actions in the test. If you click
"Set as Default" It will be available for all the new Tests.

In Test Pane.

Call functionname(parameters)
or
var=functionname(parameters)
msgbox var

2. Executefile "path of .vbs" file

It is used to execute the function dynamically but it is
used for only particular action,

Is This Answer Correct ?    2 Yes 0 No

How to call .vbs functions in QTP? plz Explain indetail..

Answer / nandishpatil

You can execute a VB Script function using the statement

ExecuteFile "File"

Eg: If you have the .vbs (MyVBScript.vbs) file in the
path "C:\Temp" then the following statement will call the
same:

ExecuteFile "C:\Temp\MyVBScript.vbs"

Is This Answer Correct ?    1 Yes 0 No

How to call .vbs functions in QTP? plz Explain indetail..

Answer / anonymous

You can Load the function into the test dynamically using the statement

LoadFunctionLibrary "Path of File"

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

How to get Traceability matrix from TD?

0 Answers  


How do I get the QTP scripts result in xml format by using vb script function?

0 Answers  


what is the Vbscript to connect Database

5 Answers   IBM,


how can we know the program is testing by multiple test data in data driven frame work?

1 Answers   CTS,


Hybrid framework supports Descriptive programming. Is it true?

0 Answers  






This is Ajay i have few douts if anybody know pls give me reply. 1. i have opend 2 gmails i am working with 1 gmail i want to close other gmail by usig script. 2.i have 10 links in a page all of them have same properties& names i want to click on 5link by using script. 3.i have one combobox in that i want to see all the citynames in the combobox and i have to check weather hyderabad is present or not. 4. size of objectrepository. 5.what r problems we get during writing the script. 6.is it possible to compare to excel sheets in qtp if possible wht is the script. 7.example for lowlevelrecording

3 Answers   Symantic Space,


How to find the number the number of Links, Brolken Links in a webpage?

3 Answers   Ordain Solutions,


I am trying to write a descriptive program for clicking on a perticular link.For that i wanted an index or location of that object.But when I viewing through spy, There was no index property of that object.What to do for getting index value.How can I get index? please any one let me know.

5 Answers  


What are the main differences of qtp and win runner?

0 Answers  


Can we record a video in qtp recording??

1 Answers   BirlaSoft,


What is expert view and keyword view?

0 Answers  


How many scripts did you have?

0 Answers  


Categories