Its not a silly question at all.
All of the below data is my own opinion and some one else may have some other views
Disadvantages of DP in QTP
1. It does not wait for the time specified in exist statement i.e. it wait for the timeout time instead of the time specified
2. You loose the option SMART identification which other wise can save your script from failing some times.
3. If you are looking in for making a dynamic OR using VBScript or XML then you can only give one argument for DP. As there is no way you can pass dynamic no. of arguments to a function using vbscript. The workaroud for this is to convert the script into description object and then use it. But that agains puts an overhead of object creation.
Advantages of DP
1. You can start coding even when your application is not ready
2. You can make changes to the script without making a change to the OR. Very useful when you are using a shared rep and you don't want to change the objects in OR as the changes may impact other test cases.
3. Helpful when you have a series of control (array of controls) in which there is small changes in the description name.
4. No need to keep same types of objects.
You can visit my site and read the tutorial on DP that covers all of the above things with explaination.
Originally posted by tonymro: </font><blockquote><font size="1" face="Verdana, Arial, Helvetica">quote:</font><hr /><font size="2" face="Verdana, Arial, Helvetica">As there is no way you can pass dynamic no. of arguments to a function using vbscript...
<font size="2" face="Verdana, Arial, Helvetica">You can use an array to pass a variable number of parameters into a function. </font><hr /></blockquote><font size="2" face="Verdana, Arial, Helvetica">I know that but the point is that while using DP in an QTP object we cannot pass properties as an array (that what i was saying exactly)
back to the original question (seem like no anwser yet ... [img]images/icons/smile.gif[/img]
Then what is the actual purpose or the benifit of using OR instead of using DP.
the benifit of using OR
- quick and easy ... as one of its main selling points of Quick Test Pro, it has the most user/scripter friendly functionality to record the objects and to create checkpoints via the Active Screen, etc.