How to create runtime property for an object?



How to create runtime property for an object?..

Answer / Amnish Kumar

To create a runtime property for an object in QTP, you can use the following code:nnDim obj As ObjectnSet obj = RepositoryItem("ObjectName")nobj.AddProperty "Runtime Property", "PropertyName", "PropertyValue", 2nThis creates a runtime property named 'PropertyName' with the value 'PropertyValue' for the object 'ObjectName'.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

What kind of performance is expected on the client side (e.g., how fast should pages appear, how fast should animations, applets, etc. load and run)?

1 Answers  


Hi, I want to write the script for a webpage. But i didn't added the properties of the objects to the object repository. Without adding the object properties to the object repository, how to write the script. When i am writing the script, Let us say i typed as Browser (""). after selecting ".", if the object is added to the object repository it will display atomatically. But in my case it is not as i didn't added the object properties. How to proceed further in the above mentioned case to write the script manually. Pls let me know if you didn't understand the question.

3 Answers  


Hi Friends this is kumar i would like to request to all of you ,please help me to explain real time project with using qtp scripts i know basics of qtp but it won't workout on interviews,pls help awating to reply.

1 Answers   SoftTech,


How will you set a unique four digit number in an edit field in QTP?

2 Answers   IBM,


I have two actions in my QTP test and two iterations in my DataSheet. I want to execute the Action 1 for the two iterations only after which i want to exceute the next Action2. How is this possible?

4 Answers  


How to create a Runtime property for an object in QTP?

6 Answers  


How can we do this one ? at runtime qtpwindow and browser aren't disply on monitor (or) aren't visible on desktop?how?

1 Answers  


How iteration is related to Test Results in QTP?

1 Answers  


While recording a login window QTP is identifying only parent window,then how can u identify the child objects.

2 Answers   Symphony,


What type of problems one will face with QTP , if too many browsers are opened at a time?

2 Answers  


What is QTP and the use of QTP in TD?

1 Answers   MaxSolPro,


How to retrieve particular cell data in excel sheet ?without importing method.

3 Answers  


Categories