How to set the function parameters as optional.

Pls anybody can give the answer.. Thanks in advance...

Answers were Sorted based on User's Feedback



How to set the function parameters as optional. Pls anybody can give the answer.. Thanks in adva..

Answer / uday kumar_anem

As far as i am aware, there is no keyword for optional
parameters in VBScripts.

Is This Answer Correct ?    1 Yes 0 No

How to set the function parameters as optional. Pls anybody can give the answer.. Thanks in adva..

Answer / saroj

In function parameter you can't use optional option. But
you can mark the statements inside the function as optional
by putting keyword "OptionalStep" before the statement.

ex:
Function login(name,passwd)

OptionalStep.Brw("login").Webedit("name").set name
Brw("login").Webedit("passwd").set passwd
Brw("login").Webbutton("ok").click
End Function

This may help you.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

Using QTP checkpoint, where do you store your expected Properties of the object which later compares with the actual properties of the object???

4 Answers  


How to find if given number is prime or not

1 Answers  


your doing one project testing then how u know itis wheather web based application or windows based application?

2 Answers  


hi all QTP recognizing objects as "string_1","string_2","string_3","string_4" like that but when using FOR LOOP for these.QTP not proceeding further can i declare these _1,_2,_3,_4 as a single variable

4 Answers   Livetek,


how can i replace any text from the qtp script with some anothere text

1 Answers   Livetek,






HI I want to know the detials of QTP certifications such as syllabus, study Materil etc. Can any provide me all these details?? my mail ID is krishnuvk@yahoo.com

0 Answers  


In smart identification, explain about 1. Base filter properties 2. optional filter properties with examples?

2 Answers   TCS,


how do we know whether all objects are stored in the object repository or not? how can we know if a particular object is not stored in the repository?

0 Answers  


suppose i opened 6browsers and i want re-open the 4browser what is code for this..pls help me..

2 Answers   Core Logic,


What are the main features we have to compulsory test by using qtp in an web based application

1 Answers  


What are the points to be taken into consideration while doing desktop testing?

1 Answers   Cap Gemini,


How will you handle java tree in qtp?

0 Answers  


Categories