Follow Our FB Page << >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...

How many ways return more then one value from function?

Answers were Sorted based on User's Feedback

How many ways return more then one value from function? ..

Answer / suresh

what is mean by that script, which statements u can write in QTP TOOL and which statements u can write in Out side QTP? write with clesr info?

Is This Answer Correct ?    4 Yes 0 No

How many ways return more then one value from function? ..

Answer / kurubaharibabu

Dear All,
I have updated all three ways the below code..

Function func1(a,b)
Dim c(3)
End Function
For i=0 to ubound(x)-1
msgbox x(i)
Function func2()
Dim c
End Function
msgbox x(0)
msgbox x(1)
Function func3()
Set dic=createobject("Scripting.Dictionary")
dic.Add "a","apple"
Set func3=dic
End Function
Set x=func3
msgbox x.Item("a")
msgbox x.Item("b")
msgbox x.Item("c")
Class user
Public var
Public cat
End Class
Function func4()
Set obj=new user
Set func4=obj
End Function
Set x=func4()
msgbox x.var

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More QTP Interview Questions

Hi, this is venkatesh. Q: I have 10 files in a folder(say D:\). Out of which there are some .txt, .xls, .doc. I want to know how to get the count of each file using qtp? If U have any ans, plz write script for that...

4 Answers   EDS,

Is it a smart choice to use QTP for backend testing?

1 Answers   CTS,

How can we import a Open Office excel file in QTP

4 Answers  

how can i pass a "automation script" as a parameter in a function give me need full suggestion thank inadvance

0 Answers   Synergy,

The Senario is Steps to do 1.Entered userid in textbox 2.saved with details 3.i want to open user which i have created its in hurry.....

1 Answers  

What does Reporter.Reortevent2 does?

2 Answers  

desribe a situation where u faced a stressful situation and how did u cope with it

0 Answers   DELL,

How do you test DLL files using automation Tool QTP?

0 Answers   Qwest,

Reverse string without mid or streverse function.

1 Answers   Deloitte,

Hi Frenz... I would like to take up the QTP certification . Can anyone tell me what is the procedure. n if anybody have the study materials pls fwd it to

0 Answers  

What are the data types in qtp?

0 Answers  

When I used random numbers(1 to 9) with regular expression and run the test, it runs only 5 iterations with passed result instead of running all 1 to 9. Please tell me what can be the reason

0 Answers