how can i pass parameters into function?

Answers were Sorted based on User's Feedback



how can i pass parameters into function?..

Answer / venkat

In the above answer (a,b) are the arguments not parameters.
And we called as arguments in functions.

Is This Answer Correct ?    5 Yes 0 No

how can i pass parameters into function?..

Answer / deven

Function MyFunction(Argument1, Argument2)
MyFunction = Argument1 + Argument2
End Function

Is This Answer Correct ?    0 Yes 0 No

how can i pass parameters into function?..

Answer / bluemoon_bala

From the information, i understand that u have written a
function and trying to pass values to that funciton..

Here is an example:
I have created a function called Add and taken two arguments
" a" and "b". And called that function by passing the values
as 2 and 3

Function Add(a,b)
c=a+b
msgbox c
end function

add 2,3

Is This Answer Correct ?    2 Yes 4 No

how can i pass parameters into function?..

Answer / sunil reddy

We will defeinitely pass the parameters to Function

Try with this Example

First parameterize the Agent name with invalid data like sun
Dialog("Login").Einedit("AgentName").Set datatable.Value
("Agent")
Call the function
Function Login(Sunny)
Dialog("Login").Einedit("AgentName").Set datatable.Value
("Agent1")
End Function

Is This Answer Correct ?    0 Yes 4 No

Post New Answer

More QTP Interview Questions

what type of run time errors you get while you ar edoing rpg program?

0 Answers  


I am in need of some set of QTP FAQ @ interview. Also recently in one of interview portal they asked me how you write the script for Login application which it is web -based and using Descriptive Programming? Without associating the shared object repository?Please i do need this answer very soon? Please respond me soon @ vaisu72@yahoo.com

2 Answers  


Cn u please clarify my doubt Where are micTab and micReturn used.Thanx in Advance

2 Answers  


Hi, How to invoke QTP or any application through Command Prompt without using Vb script and batch file.... Reply me Srinivas

3 Answers   Excel,


How to Practice QTP Scripts?

1 Answers  






How many types of actions are there in quicktest professional (qtp)?

0 Answers  


When and why to use descriptive programming?

0 Answers  


How the objecs properties are identified?Tell me in Hierarchical order?

5 Answers   IBM,


I want to open a text file and then search some specified text in it and then replace that text with some other text i found that text in .txt but do not know how to replace that text can any body help me. if possible put the code for qtp

2 Answers  


I am trying to install QTP 9.5 but i am getting error message saying that ("Path is \QuickTest Professional\bin\vb_init.exe") vb_init.exe file is not find. can anybody give me the advise what to do ?

0 Answers  


Please explain the role of Regular expression in QTP

0 Answers  


i want to handle all the unwanted pop up through QTP i done that with recovery scenario but it need some title of pop up but i want that it should handle all the pop up even i don't give the title of that pop up in recovery scenario is there any general way to handle all the pop up please help

3 Answers  


Categories