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 / siri
'vbscript
dim a:a=20
dim b:b=30
dim d
d=add(a,b)
call subtract(d)
function add(a,b)
dim c
c=a+b
add=c
end function
function subtract(d)
dim f:f=10
dim e
e=d-f
msgbox e
end function
Is This Answer Correct ? | 6 Yes | 3 No |
Post New Answer View All Answers
Which operator is used to concatenate the 2 values in the vbscript language?
How to Convert Hex color code to color name in VB Script?
What methods are used to create text files and open text files in the vbscript language?
wht must be the interview question on corinthian information technology solutions incorporated.
how to automatically update the sql server2005 database records when insert in vb6?
Mention if qtp generates vbscript code as we record actions, can't it possible to directly write using vbscript code when qtp does the same thing too?
What are the 2 ways to pass a value to the function?
How will you get the exponent of the given number in vbscript?
What is the technology used by vb script?
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.
Mention how to access array data?
how to comvert 120 into one hunderd twenty rupees only and vice varsa
How can you create an object in vbscript?
What are the data types supported by vbscript?
what is the standards used for writing the script in QTP