How to record the double click actions - Printable Version +- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums) +-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP) +--- Forum: UFT / QTP Others (https://www.learnqtp.com/forums/Forum-UFT-QTP-Others) +--- Thread: How to record the double click actions (/Thread-How-to-record-the-double-click-actions) Pages:
1
2
|
How to record the double click actions - venkatbatchu - 08-11-2009 Hi All, Please observe the attached screen shot My scenario 1) is--> I need to record some of double click actions in my application 2) Need to perform double click on particular value, how to do this action on specific value Please let me know if u have any solution for this Thanks, Venkat.Batchu RE: How to record the double click actions - basanth27 - 08-11-2009 Please ensure you provide us some kind of minimal technical details before you post. 1. What is the object which is holding the values ? 2. Have you tried to spy on it ?? Quicker the reply, quicker the reply. RE: How to record the double click actions - Saket - 08-11-2009 although I agree with Basanth's Sugestion - if you can post more technical details then we can defintely help you in better way. If I have understood it correct you want to a double click operation on a particular object I can suggest you for the second scenario 2) Need to perform double click on particular value, how to do this action on specific value get the x, y co-ordinates of the object on which you want to perform the double click. Create and object of Mercury.DeviceReplay use Code: object.MouseDblClick( x, y, Button ) where Object is device replay object and possible values for Button can be LEFT_MOUSE_BUTTON = 0 MIDDLE_MOUSE_BUTTON = 1 RIGHT_MOUSE_BUTTON = 2 RE: How to record the double click actions - basanth27 - 08-11-2009 Saket - DeviceReplay might not always be the best solution to perform. In a application where the co-ordinates change dynamically, you may need to perform few modifications to the axes obtained before clicking on it. Always we would first need to find the object and explore all the possibilites of a doubleclick action. If not available then we may proceed with API's or DeviceReplay or Sendkeys etc... Just a suggestion :-) RE: How to record the double click actions - venkatbatchu - 08-11-2009 Hi, Please find the attached screen shot for more information. While recording the double click action script is generated for this scenario... Regards, Venkat.Batchu RE: How to record the double click actions - basanth27 - 08-11-2009 This helps. Add the webtable object to your Object repository and paste the below code in the expert view and execute it. Code: rowcount = Browser().page().frame().webtable().rowcount Let me know if it helps. Please be aware that the most skeletal part of a raw code has been supplied to you. Please tweak according to your requirement and your coding standards. Logic is the only part which remains untouched. RE: How to record the double click actions - venkatbatchu - 08-11-2009 Could you please share the information about "Sendkeys" i.e, windows script like any kind of tutorial or documents related to this.... RE: How to record the double click actions - basanth27 - 08-11-2009 Did you try QTP Help ?? I wish you had done it since it is right in there. Just type SendKeys and you will get plethora of information about it. On a sideline check this out, http://msdn.microsoft.com/en-us/library/8c6yea83(VS.85).aspx RE: How to record the double click actions - venkatbatchu - 08-11-2009 Hi, I tried with your valuable suggestion but i am getting little problem for this please find the attached screen shot... RE: How to record the double click actions - basanth27 - 08-11-2009 Try this, Code: Browser().page().frame().webelement("name:=Venkat.*").Firevent "ondblclick" Does this work ? Sorry, I mislead. Try this, Browser().page().frame().webelement("innertext:=Venkat.*").Firevent "ondblclick" |