What about xpath? For 1 you can use a pretty restrictive xpath to verify the location in the dom, in your example //tab...@id='tableCustomerData']/tr[1]/td[1].<mailto://tab...@id='tableCustomerData']/tr[1]/td[1].> You could store that xpath and then verify the property or get fancier with the xpath to do the verification within the xpath
For 2 you could use following:sibling if your data is in a table. //tab...@id='tableCustomerData']/tr/td[contains(.,'yourCustomerId)]/following-sibling::*<mailto://tab...@id='tableCustomerData']/tr/td[contains(.,'yourCustomerId)]/following-sibling::*> Again you could store the xpath and verify the property or possibly get fancy with xpath to do it for you. Hope this helps, I think xpath might be the solution you are looking for do a google search for xpath tutorial and go through the w3cschools tutorial if you don't know about xpath. http://www.w3schools.com/xpath/ ________________________________ I guess you could do all that with scriptStep and some JS scripting: http://webtest.canoo.com/webtest/manual/scriptStep.html I might be wrong though, I am still a newbie at this - others might provide more insight. Enjoy! On Thursday 18 February 2010, Gert Pauwels wrote: > Hi, > > > > We have been using Canoo for quite some time now, and are always looking to > extend its use. I have two issues I'd like to discuss: > > > > 1 verifying text for its exact location on the screen > > 2 verifying texts that on screen are displayed next to each other (but > source page contains tabs etc.) > > > > 1 Verifying text and exact location > > > > Our webpage is divided into several sections. Each section contains a > number of fields in any number of rows and columns. Let's look at one > field. If for instance Customer ID is on my screen, it will have specific > location (row 0 = top row, column 0 = left most column). I can verify that > the field is present alright, but I would like to find a way to determine > its exact location. If my field is in row 2, column 1 then I need to be > able to that in Canoo. The question is how? (I've attached a screenshot) > > Example: > > > > first column caption: Assigned to > > first colunm value for that field: Richard Branson > > > > second column caption, row 3: Branch Name > > value for this field: Tokyo Branch > > > > How do I make Canoo know that the value Tokyo Branch is the value for > Branch Name, and not for the Assigned to field? > > > > 2 Verifying text next to each other > > I need to find a way to determine whether for the text on the left hand > side of the screen the text on the right hand side of the screen matches a > given value. Looking at the source of the webpage, I cannot find any hooks > to tie myself onto for this. An example: > > > > Check on EU List (some spaces, tabs or whatever later, invisible to the > user) Alert > > Check on OFAC list (some spaces, tabs or whatever later, invisible to the > user) Pass > > > > When running Canoo, I need to be sure that when I verifyText 'Alert' this > is for the value 'Check on EU List' and not for any other text that may > appear on the same page. > > If possible, how? > > > > Thanks for your assistance > > > > Gert Pauwels > > _________________________________________________________________ > Hotmail: Free, trusted and rich email service. > https://signup.live.com/signup.aspx?id=60969 > _______________________________________________ WebTest mailing list [email protected] http://lists.canoo.com/mailman/listinfo/webtest

