| || |
DHTML, DIV, Layer, IE, NSCP, Consistent .INC Decls, Sheesh!
OK, I promise I'll try to keep this concise :^}
The AUT generates reports in browser specific DHTML. One significant portion of a report is a "grid" ... think of an Excel spreadsheet. Except that it's NOT an HTML table -- it's just a series of textfields aligned via the magic of DIV / Layer tags and appropriate positioning. To add to the madness, it is possible to "expand" or "collapse" rows and columns ... think of an Excel spreadsheet that uses grouping.
Here're the problems I'm trying to address:
1) Under IE 5.0 (using Silk 5.0.1, not the 126.96.36.199 DOM stuff ... yet) if I generate the SAME report twice, Silk sees the "grid" differently. Sometimes it thinks that parts of the grid are an HTML table, sometimes it doesn't. The underlying DHTML source is identical, so I know that isn't the root of the problem. Funny to note that for the first time in history, NSCP 4.7 is actually more reliable than IE in this area -- I get the same window decls most of the time. Note that I'm not strictly trying to generate the decls over-and-over, it's just that I immediately had problems accessing objects and started to explore -- when I determined that the access problems were due to Silk not seeing the same report the same way twice!
2) Anyone have any slick techniques for accessing a dynamic / interactive grid? I'm trying to avoid the need to declare hundreds (thousands) of page decls to cover all the possible states of a given grid. Since it's not an HTML table, I don't get the luxury of row/column type addressing. Every cell is effectively a link. Note that the cell values in the grid can easily occur > 1 time -- that is there can be several cells containing "100", and I can't think of a nifty way to know which "100" I'm accessing if I simply say [HTMLTextField]/"100" (syntax approximation) to access it without a stable declaration.
Now, I'm perfectly willing to move to 188.8.131.52 and the DOM (for IE) and bite the bullet to create tons of duplicate include files (or browser type specific tag / declarations) if that's what it takes, but I thought I'd solicit the collective wisdom of the world for alternatives.
Re: DHTML, DIV, Layer, IE, NSCP, Consistent .INC Decls, Sheesh!
I wouldn't recommend trying to capture window declarations for pages such as you are describing. You can reference the objects on the page dynamically.
You can try the functions at http://www.automationexpertise.com/Files/aeweb.inc. This library has functions which allow you to click links or images, regardless of whether they reside in tables, or in which table they reside. Also, there is a function called LinkPathClick, which will allow you to click a link based on its URL, rather than its caption. If you know that one of your "100" links points to a different URL, this function will allow you to specify the one you want.
A tutorial on using the aeweb functions will be available next week.
If you have any trouble using the functions, email me. I have a beta version of the library which is recursive on nested tables.
Hope this helps
John W Green