I have below user Defained function

function AddTwo(ByVal a, ByVal b)
Dim Ans
Ans=a+b
MsgBox Ans
End function
Now my question comes here...from given below methods which
method is right to call above function?Which is Wrong and why?
1. AddTwo(2,4)
2. Call AddTwo(2,4)
3. AddTwo 2,4
4. Call AddTwo 2,4



I have below user Defained function function AddTwo(ByVal a, ByVal b) Dim Ans Ans=a+b ..

Answer / sisira

 Call AddTwo(2,4)
 AddTwo 2,4
these two ans are true





Thanks
sisira

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More QTP Interview Questions

I got an error "The"flightres" Dialog was not found in the Object Repository. Check the OR to confirm that the object exists or to find the correct name for the object." while running the following script Set flightres=description.Create() flightres("text").value="Login" flightres("Class Name").value="Dialog" Set agent = description.Create() agent("nativeclass").value="WinEdit" agent("attachedtext").value="Agent Name:" Set pwd = description.Create() pwd("nativeclass").value="WinEdit" pwd("attachedtext").value="Password" Set button = description.Create() button("nativeclass").value="WinButton" button("Text").value="OK" Dialog("flightres").WinEdit("agent").Set "test" Dialog("flightres").WinEdit("pwd").Set "mercury" Dialog("flightres").WinButton("button").Click Please let me know if i made any mistake in the above script...?

4 Answers  


How many types of OBJECTS are there in QTP?

8 Answers   Intel, Inter Globe Technologies,


What is the difference between Datadriven and Parameterization?

8 Answers   Ordain Solutions,


how will check the links in multiple pages at a time

3 Answers  


What are the different types of recording modes?

0 Answers  






write string reverse prog using vb script with out using string reverse statement();

4 Answers  


how to acess a test in RSA?

0 Answers   IBM,


pls tell me how will you write the vb script in QTP for DataDriven test from Excel sheet for multiple userid and password explain with example

6 Answers   Ordain Solutions,


Hi. I have completed B.TECH(CS) , But I will go to "SECURITY CONSOLE OPERATING" [C.C CAMERA abservation]. IF interviwer asks " Why you choose this job ?" What we will say? urgent.........................urgent...........

0 Answers   IBM,


Hi guys pls any one send me the Qtp Licensed key of version 10.0 pls

0 Answers  


What is SQL injection?

2 Answers   CTS,


what is the extension for QTP files?

11 Answers   AppLabs,


Categories