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
How are values assigned to string type and numeric type variables?
Explain about the functionality of vb script?
If else for do while select in vb script?
What is the use of option explicit in vbscript?
Can u describe what kind of testing are for OTC derivates by banks.
Set srchobj=Description.Create() srchobj("type").value="text" srchobj("name").value="q" srchobj("html tag").value="input" browser("micclass:=google").Page("micclass:=google").webedit (srchobj).Set "qtp" what's wrong in my code pls tell me ? the above code working fine and i got my result pass,now i am trying to run the program it shows general run time error why?pls help me i am in learning stage ?
We have 1 web page with names column. I am giving the Service Providers1,2,3.... @ that time dynamically some no of names are displaying in the webpage and The Pop up windows are opening(No.of Pop Up windows=No.of Names). The names may be diffar for each and every Service Provders (Dynamically) How can we handle the Dynamic values?
I have attended Anovatek Software QTP interview. They will give us computer and one web based application with QTP. We have to automate some records (already updated records or new records) using QTP Data driven testing. But we should use for loop? Can any one know how to do data driven testing using For loop?
Explain the scope of the variables using dim, public, and private keywords respectively.
Write a code to print numbers from 5 to 0?
What are string functions in vbscript?
How will you get the last occurrence of one string within another string using vbscript?
how to write validation function for date in vb script
Hello Guys, If any body looking for "worksoft certify tool training in bangalore", please contact me aimansaud@gmail.com
How will you get the natural logarithm of the given number in vbscript?