How to Pass Multiple values in functions by using vb script?
Function value(arg1,arg2)
N1=arg1+arg2
N2=arg1-agr2
N3=arg1*agr2
N4=arg1/arg2
Value= How to pass ?
End Function
Answers were Sorted based on User's Feedback
Answer / lak
Function value(arg1,arg2,N)
N1=arg1+arg2
N2=arg1-arg2
N3=arg1*arg2
N4=arg1/arg2
Value= N
End Function
call value(10,10,N1)
msgbox N1
call value(10,10,N2)
msgbox N2
call value(10,10,N3)
msgbox N3
call value(10,10,N4)
msgbox N4
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / sureshkumar
Function value(a1,a2, res)
res=a1+a2
res=a1-a2
return res
End Function
call value(10,10,res)
print res[0]
print res[1]
| Is This Answer Correct ? | 2 Yes | 5 No |
Suppose by navigation I went from 1 st page to 5 page ,so Write a generic script for coming from any page to the 1st page and by executing where the page may be it will come to 1st page
Explain about constants in vb script?
what does create object actually do when you call it in vbscript?
why variable name should not exceed 255 characters?
When does ‘on click of button’ event gets triggered in the vbscript language?
reverse the string without using reverse string?
Can anybody code this problem for me in VB script - Create an array of 4 elements, increase its size to 7 elements and then find out which of the elements are prime (use functions)
Can automation testing find ssame no. of bugs what we can find by manual testing?
I have a webtable and many objects are embedded in side.(like buttons,checkboxes etc). How to know how many such objects are there? what is the class of that objects?
What are the 2 ways to pass a value to the function?
Could Anybody tell me the Script for REVERSE an Interger int reverse(int num) Ex:246 to 642.. Thanks in Advance.
how to store charecters of HARIBABU Using arrays