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...

I am just a beginner in QTP. Could any one explain me in
detail how to automate adding two numbers and getting the
result in QTP. Also I would like to parameterize the
inputs. I have tried but getting an error like 'Can't use
sub.....'(can't recollect the exact error)

Answer Posted / ram

you can write function to add two numbers and call in qtp.

file-->New-->function Library

Public function add(a, b)
add=a+b
End Function


Save it where ever u want with add.vbs

Now File-->settings-->Resources-->Add function library--
>click at add(+) button below one button will appear click
that and add the saved library file(add.vbs).

in qtp normal file

write print add(4,5) and u can parameters as your wish.



add this in

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of "New Property" in "Add properties" of testobject properties in object repository. How can i use "New properties" while writing scripts if i have assign some values to the testobject properties Can anyone help me? plz

1933


tell me abt a time when u had to go above &beyind the call of duty to get the job done

1880


How will you find the current time of the remote machine using QTP script?

1003


What is meant by a Check Point in UFT? Also, explain the applicable Check Points.

1121


How to connect to a database?

1065


can anyone tell me from where i can download qtp demo or crack version

1940


I used child objects to get the no of weblist present in the weblist.now i need to select the items present in each weblist ?How to do so

2642


You will receive the mail in your outlook from client at night time to go ahead for the execution. Based on the mail you need to trigger the batch run. What is the QTP Code for this?

1846


Can I change properties of a test object?

1081


What is an expert view and keyword view?

1056


Can anyone pls tell me how to do action parameterization (input and output parameters) with respect to login window and insert order of flight reservation window in detail( pls give a clear step by step explanation with example) anyone please. Will be very thankful to u

1747


How does qtp identify objects in the application?

1073


What is the differences between image check point and bit map check point?

1006


how can you do retesting (datadriven test) using notepad amd by using functions NOTE u should not use datatable methods

1867


what kind of frame work you used in your last project?

2268