RadTree + Quick Test Professional

5 posts, 0 answers
  1. Tim
    Tim avatar
    169 posts
    Member since:
    Apr 2008

    Posted 06 Jun 2008 Link to this post

    Is there is any way to make the objects in the RadTree tree structure have unique ID’s to define them? We are Using Quick Test Professional 9.5 and the tool can record the objects however, there is no property to uniquely define the object.

    Need to have some way to have -+ objects used to expand and collapse the tree, the Name field (Node), and the Icons  be able to have unique way to identify them.

    Property options to make unique that QTP can recognize: Class, ID

    Thanks,
    Tim

  2. Helen
    Admin
    Helen avatar
    1052 posts

    Posted 10 Jun 2008 Link to this post

    Hello Tim,

    IDs of items are used for internal purposes. Also RadTreeView for ASP.NET AJAX does not render IDs for the items in order to reduce the output size.That is the reason why we suggest using of custom attributes instead of ID property.

    Besides, we use Selenium for integration testing. It is a free tool which currently fits our needs for the present.


    Regards,
    Helen
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Tim
    Tim avatar
    169 posts
    Member since:
    Apr 2008

    Posted 12 Jun 2008 Link to this post

    Do you mean something like this?  It adds some attributes to the JS which creates the tree, but my DOM browser doesn't show them attached to the individual html nodes.


    private static void QTPDecorate(RadTreeNode node) 

        node.Attributes.Add("SEQUENCE", SEQUENCE.ToString()); 
        SEQUENCE++; 

     

  4. Helen
    Admin
    Helen avatar
    1052 posts

    Posted 13 Jun 2008 Link to this post

    Hi Tim,

    You should use valid attributes only - like id, otherwise they will not be rendered client-side. Please see for reference the code below:

    protected void Page_Load(object sender, EventArgs e)  
        {  
            for (int i = 0; i < RadTreeView1.Nodes.Count; i++)  
            {  
                RadTreeView1.Nodes[i].Attributes.Add("id", RadTreeView1.Nodes[i].ID);  
            }  
        } 

    Hope it will be helpful.

    Greetings,
    Helen
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  5. Isaac
    Isaac avatar
    21 posts
    Member since:
    Dec 2008

    Posted 26 Jan 2009 Link to this post

    Hi. For a project we are working on, we are using QTP as well. There is no way I know of, short of writing a custom Add In for QTP, for QTP to recognize RadTreeView. I settled on using QTP in Low Level Recording Mode when there is a control that QTP cannot recognize. This simply calls Window("Name Of Browser").WinObject("Name of Widow").Click x, y . Where x and y are the coordinates of the mouse click. That should work. We are still testing this.
Back to Top