could u pleas give some tips and notes to write Discriptive programing
Printable View
could u pleas give some tips and notes to write Discriptive programing
Hi,
Descriptive programming needs no repository
U add the objects & define the repository on ur own
Only thing is you need to have command on VB scripting
Thanks,
Kamal
In DP another advantage is that whenever there are 2 or more fields which have the same name or description property.... you can identfy the system with the unique properties like index.
DP also helps when the objects property when recorded is not identified at runtime. So you just use other properties which are identified at runtime.
To code descriptive programming we need to spy the object and read the unique physical propert(y)ies of the object...these are syntax
CalssName("property:=<Physicalpropertyname")
example,
Browser("name:=Google").Page("title:=Google").Link("name:=Search").Click
Descriptive Programming is something which you enhance the script generated after you record. Remove the unwanted script and include the user defined functions, logic and parameterize the script upto the needs.
Declaring and making use of environment variables, passing the values, working with userdefined functions, sub procedures..etc will make script enhanced to descriptive programming.
As Raghav and Dableena said, we should have a good command on vbscripting, logic building..etc. And coming to objects Names we shall directly refer to name space for all the objects in application without using object repository. Use the appropriate/unique object properties to identify the same. This will really enhance the script. It totally eliminates the object repository dependebility.
This is descripting programming. Hope the info. is useful.
Arun*
hai kamal,
thank u for ur answer. i have one more doubts on qtp.
how to prevent sharing qtp scripts from others.