Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to call the userdefined functions to script? If i am
stored 'add()' function in Library functions folder. i want
to cal that function in my script.

Answers were Sorted based on User's Feedback



How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / murali raju

Instead of add name put the add1 as ur function
name...because add is keyword

Function add1(a,b)
c=a+b
add1=c
End Function 'put the function .vbs file and save it c
drive with the file name addition.vbs

write the below script in ur qtp

ExecuteFile "c:\addition.vbs"
x=add1(2,4)
msgbox x 'it will be prints 6 in the msgbox

Is This Answer Correct ?    1 Yes 0 No

How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / pramod

But your code is giving me acess denied error

how to save the function as .vbs thorugh QTP or VB

Is This Answer Correct ?    0 Yes 0 No

How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / murali raju

Hello...pramod..Put the function in notepad and save
as .vbs extension then call through the above execute file
statament in qtp ...ok.na..

Is This Answer Correct ?    0 Yes 0 No

How to call the userdefined functions to script? If i am stored 'add()' function in Libr..

Answer / umesh

Save your functions in a notepad and save it as a .vbs file.

Under Test Settings - Resources tab, Associate your .vbs
file as a Library.

Call the .vbs file as a header in your script and use all
the functions.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

what are the settings to be done to make the recovery scenario created for one test to be used bye all the other tests. please tell me recovery scenario process in detail.

1 Answers  


Explain in brief about the quicktest professional automation object model?

0 Answers  


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

4 Answers   Wipro,


Waht is User interface and Integration Testing?

1 Answers  


X flies from Hyd to bangalore using different methods of transportation. write the test scenarios and test cases for this?

0 Answers   Virtusa,


write a qtp script to verify that the business price is twice the economy price in flight reservation window

1 Answers  


I have the script like this: Browser("Philips Web Login").Page("Philips CL DMS2 Application").Frame("ScopeFrame").Link("DC3701737 (Active)").Click in which the value "DC3701737" will get changed and i have to use the same value in so many places. If i want to get that value "DC3701737" in to a variable, how? pls let me know if you didn't get the question. Help me out in this.

2 Answers  


Got job with 3 years fake Experience

1 Answers   MNC,


Explain step generator in qtp?

0 Answers  


Hi All, issue is related to handling pop up script generated in IE, and run on mozilla. In App Under Test, when we get the alert pop ups, we just click ok button. if we need to run the same code on mozilla it will not identify . so we will check browser if browser(*).dialog(IE object).exits browser(*).dialog(IE object).winbutton(OK).click else 'by default mozilla browser(*).dialog(mozilla object).page(*).webbutton(OK).CLICK END IF But my qustion is. Do we write the above piece of code where ever we get such kind of pop ups from the application like alert pop up, confirmation pop up.... OR do we have any other alternative way to do this by using any functions in Recovery Scebarios? If Any of u know idea please do help me in this regard. or send answer to kravimb@gmail.com

0 Answers  


How to supress warnings from the "Test results page"?

2 Answers  


one ok button and one text box is there.when i click on ok button in that text box one no. will display from 1 to 100 randomley.if that is not 100 when we click on ok button again ,again another text box ll created with another no. we will continue this till the text box created and displays 100.and when its 100 ok button should disabled. remember thet no will display not seriely ,it displays randomley,and each time new text box will created.

6 Answers   ADP,


Categories