Scenario:
My application developed in: WPF
-- QTP is not generating script for WpfMenu items. For example File->Menu. While recording when you click on File and Menu items QTP is not generating script automatically.
-- When you do object spy for menu item i can able to see object properties. My question: If QTP is not generating script, how to add object properties to repository?
Try the other way , dont record your application instead add the objects to the repository and drag and drop them onto the Keyword view and see what happens , since object spy is able to acquire the object properties it should be able to generate the relevant commands... Try reinstallating the .net add in ...
Balaji -
Not always does QTP record and generate scripts. If there are third party add-ins then although it recognizes it is difficult for it to write the scripts.
IamShekar -
Add the objects to the repository and build your script from there, see if that helps. IF it works,well and good...else find out what is the underlying architecture of the application.
Basanth Give a fish to a man and you feed him for a day..Teach a man how to fish and you feed him for life.
06-30-2010, 04:34 PM (This post was last modified: 06-30-2010, 04:52 PM by balaji4u.)
Not always does QTP record and generate scripts. If there are third party add-ins then although it recognizes it is difficult for it to write the scripts.
hi Basanth ,
I am new to QTP but based on your answer i have a doubt , if QTP can recognize an object any third party object for that matter why is it hard for it to generate the script . The internal scripting engine just takes the user actions on the objects and converts into a script so i feel the critical part is identifying the object rather than generating script so in the above stated example the object is acquired and the job of scripting engine is to replace user actions with commands , i feel scripting engine is framework or object independent . Can you please explain how exactly it works and why it cannot generate the script .
Balaji -
Ideally it should, and you will see in most of the cases that it does..However, when it comes to third party applications, identification happens because of the associated add-ins(not the ones which come defaulted with qtp) but the supportive ones which QTP cannot read and write as script.
Please excuse my knowledge about the scripting engine of QTP, I am unsure how it was designed and how it co-relates with framework or object identification. The reason it is hard for it to write is because of its inability to co-relate a custom object properties and then generate a script based on it.
Basanth Give a fish to a man and you feed him for a day..Teach a man how to fish and you feed him for life.