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 can we return a value from User Defined Function ?
For Eg. we have 2 functions. In Fun1 i am getting 2 values
(a,b) and i am addding those 2 and storing in to another var
(c). Now i want to pass that var(c) to another function
(fun2). What will be the script?

Answer Posted / varun

dim a,b,c
fun1 a,b,c
fun2 c
msgbox("done")

sub fun1(a,b,c)
a = cint(inputbox("first number"))
b = cint(inputbox("second number"))
c = a + b
End sub

sub fun2(c)
msgbox(c)
end sub

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the purpose of the err object in the vbscript language?

1053


What is the difference between VBScript and JavaScript?

2644


who will create the object?

1923


What is the scope of a constant declared using public?

933


What is the main difference between function and sub-procedure?

999


Write a vbscript procedure that converts feet to inches. Hint: there are 12 inches in a foot?

996


What are the special sub-types in vbscript?

1002


Explain about scrrun.dll?

911


Which operator is used to perform the comparison among 2 operands in the vbscript language?

910


Explain some uses of vb script?

927


Develop a parameterized action that accomplishes the following a. Launch a browser of users choice ( example : IE, chrome etc) b. Open up a search engine (Google, Bing etc) c. Perform a search d. Click a particular link depending on the user’s choice ( 1st , 2nd or third link)

1815


What are class variables?

995


Explain about operator precedence in vb script?

1024


Hello friends..... Can any give the methods for Ms-Access, and Mozilla firefox in Automation Object Model in QTP. Please give me currect answers... if you do not understand my question please don't give answers. Thanking you.

2300


1) How can we use VB script in testing the application? 2) What all are the things(Software application to be installed in PC) we need to learn VBscript?

3987