I am trying to have a recorded test test click on an item in a RadTreeView list on a HTML webpage, in this case called "2. All Reservations". But, the item title/name may not always contain the number "2." and may not be at the same index in the list, so I was hoping to find it and click it by the name "All Reservations". Here's more information below.
When I record the event in Test Studio, get the following entry (I replaced part of the navigation link with [some_code]):
RadTreeView('ctl00_ctrlMenu1_Menu'): '2. All Reservations ' action -> 'Navigate' to '/NewFormView.aspx?[some_code]'
Viewing the properties of the RadTreeNode, the html code is the following:
<div class="rtMid rtSelected rtHover">
<span class="rtSp"></span><a title="2. All Reservations" class="rtIn" href="NewFormView.aspx?[some_code]" target="_parent">2. All Reservations </a>
</div>
Editing the step in code, I receive the following (I replaced part of the navigation link with [some_code]):
'RadTreeView('ctl00_ctrlMenu1_Menu'): '2. All Reservations ' action -> 'Navigate' to 'NewFormView.aspx?[some_code]'
Pages.Home.CtrlMenu1MenuDiv.NavigateNodeByText("2. All Reservations ")
Is there a way for me to find the item by some sort of "text contains", or is there another way of finding that element in a repeatable way?
Thanks,
Tim
When I record the event in Test Studio, get the following entry (I replaced part of the navigation link with [some_code]):
RadTreeView('ctl00_ctrlMenu1_Menu'): '2. All Reservations ' action -> 'Navigate' to '/NewFormView.aspx?[some_code]'
Viewing the properties of the RadTreeNode, the html code is the following:
<div class="rtMid rtSelected rtHover">
<span class="rtSp"></span><a title="2. All Reservations" class="rtIn" href="NewFormView.aspx?[some_code]" target="_parent">2. All Reservations </a>
</div>
Editing the step in code, I receive the following (I replaced part of the navigation link with [some_code]):
'RadTreeView('ctl00_ctrlMenu1_Menu'): '2. All Reservations ' action -> 'Navigate' to 'NewFormView.aspx?[some_code]'
Pages.Home.CtrlMenu1MenuDiv.NavigateNodeByText("2. All Reservations ")
Is there a way for me to find the item by some sort of "text contains", or is there another way of finding that element in a repeatable way?
Thanks,
Tim