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 / sangee

Call add(40,20,c)
Call subs(c,10)
Function add(a,b,c)
c=a+b
msgbox c
End Function

Function subs(c,d)
e=c*d
msgbox e
End Function

Is This Answer Correct ?    6 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which operator can be used to check if two numbers are equal or not in vbscript?

1098


How to use QTP Object in .vbs(vbscript file) file Ex: Browser().., wait(), exist() and etc...

3382


Mention the rules for using option explicit statement?

929


how to write a vb script in QTP for yahoo registration form, i want to check the performance also like performance test, stress, load test like that.

5157


What is the use of the instr function?

998


Explain some uses of vb script?

921


What is purpose of scripting.filesystemobject class in vbscript?

1063


Mention what are the rules to name variable in vbscript?

963


How can constants be declared in the vbscript language?

947


How to create a cookie using vbscript?

1123


What is the difference between a dictionary and an array?

997


What is loose binding? Why is it not a good practice to use it?

1051


Mention what is the technology used by vb script?

921


how does vb script help in web page designing? explain with example.

1936


How will you convert a string to lower case string using vbscript?

967