Handle Custom Grids/ Perform actions like (Add/Edit/Delete/Search) by selecting element in Grid

8 posts, 0 answers
  1. N1t1nA
    N1t1nA avatar
    37 posts
    Member since:
    Mar 2011

    Posted 12 May 2011 Link to this post

    Hello

    In my application Custom Grids (Not Related to AJAX and RAD) are there, see attached snapshot <<custom grids.png>>.

    I want to perform following actions like Search.

    1. Example if I search like 200 and I want to Select 610200 or may be any other number 583200 in the grid, these values may vary Change there position at Runtime.
    2. How do I find '610200' if exists in Grid List and Select that Result. 
    3. After successfully find the Element and select i want to perform further actions on it like Edit/Delete data from grid.
      

    Here is Code which appears in Pages.g.cs file when i Select the 610200 and Add to Project elements.

    public ArtOfTest.WebAii.Controls.HtmlControls.HtmlSpan ContentplaceholderGridViewAccountsCodeGridLabelSpan 
    {
        get
            {
    return Get<ArtOfTest.WebAii.Controls.HtmlControls.HtmlSpan>id=ctl00_Contentplaceholder_GridViewAccounts_ctl07_CodeGridLabel", "tagname=span");
             }
     }

    Kindly help to resolve these kind of issues.

  2. Stoich
    Admin
    Stoich avatar
    1 posts

    Posted 17 May 2011 Link to this post

    Hello Nitin,
       check out this KB article:
    http://www.telerik.com/automated-testing-tools/support/kb/going-through-each-cell-in-dynamically-generated-grid.aspx
    It details how you can go through all the cells in a grid. In the article the only thing we do is print each cell's TextContent:
    Log.WriteLine("Cell found. TextContent:"+c.TextContent);
    However, you can check whether you've found the cell you want and then break the look like this:

    foreach(HtmlTableCell c in r.Cells) {

    if(c.TextContent.equals("some content I'm looking for") {
    HtmlTableCell myCell=c;
    break;
    }

    }

    Greetings,
    Stoich
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get now >>

  3. N1t1nA
    N1t1nA avatar
    37 posts
    Member since:
    Mar 2011

    Posted 27 Jun 2011 Link to this post

    Hello Stoich

    In my application,  ASP .NET Grid control used, Grid is created through Code, When I click on Particulat row It is recognized as TableCell or LabelSpan.

    My Requirement is to make Data Driven Tests and Select particular result in by matching the contents from Excel File.
     
    For example in My Application there are many account numbers binded via TableCell or appeard as grid.
    160001
    170001
    180001

    I need to Select Two accounts one by one by matching the Contents from Excel file,
    Excel contains:-
    160001
    180001

    Kindly Help?
  4. Stoich
    Admin
    Stoich avatar
    1 posts

    Posted 30 Jun 2011 Link to this post

    Hello Nitin,
            as a paying customer you're entitled to GoToMeetings. I'd like to guide you through this automation task directly on your machine via screensharing. I feel this would be the best options since it's going to be hard to get the specifics right without looking at the DOM hierarchy of your app. Please go ahead and suggest a time I'll schedule a meeting.

    All the best,
    Stoich
    the Telerik team
    Register today for a live 'What's New in Test Studio R1 2011 SP2' event on Tuesday, July 19 at 2pm EST!

    Have you looked at the new Online User Guide for Telerik Test Studio?
  5. N1t1nA
    N1t1nA avatar
    37 posts
    Member since:
    Mar 2011

    Posted 18 Jul 2011 Link to this post

    Hi Stoich
    As you know we are facing problems with our Grid Controls(Custom Grids)

    Unable to Select the Data from Gridview as it is recognized as cell

    We need a Live Meeting so that we can share directly our application with you

    I would suggest 19th July 2011 3:00 PM IST for that, If you are comfortable, please share a GoToMeetings URL with me.

    Thanks
    Nitin
  6. Cody
    Admin
    Cody avatar
    3360 posts

    Posted 18 Jul 2011 Link to this post

    Hi Nitin,

    Stoich is out on this week. I will take over in his absence. I am located in Austin, Texas, USA. I'm afraid the only reasonable time I can meet you (due to the time difference between us and my availability) is your 8pm (my 9:30am) on the 19th. I will send you a meeting invite assuming that can work for you.

    Best wishes,
    Cody
    the Telerik team
    Register today for a live 'What's New in Test Studio R1 2011 SP2' event on Tuesday, July 19 at 2pm EST!

    Have you looked at the new Online User Guide for Telerik Test Studio?
  7. Cody
    Admin
    Cody avatar
    3360 posts

    Posted 20 Jul 2011 Link to this post

    Hi Nitin,

    Just to document the results of our GoToMeeting today:

    1) I showed you how to find content in a table and click on it via a coded step
    2) I showed you how to correctly use a dialog handler in a coded step

    Greetings,
    Cody
    the Telerik team
    Register today for a live 'What's New in Test Studio R1 2011 SP2' event on Tuesday, July 19 at 2pm EST!

    Have you looked at the new Online User Guide for Telerik Test Studio?
  8. N1t1nA
    N1t1nA avatar
    37 posts
    Member since:
    Mar 2011

    Posted 20 Jul 2011 Link to this post

    Thankyou Cody for Solving the Issues.
Back to Top
  Cast Your Vote at DevPro Connections! Cast Your Vote at  Win IT Pro Connections!