Thanks for your suggestion. All the 7 elements in the page are recognized as
"links" when they are in "enabled" states and in that situation, I am able to
click all of them using 'ie.link' commands similar to the one given below:
ie.frame("Detail").link(:text,"Step 2. Inventors").click
But, when the web page first loads, only one (it is displayed as "Step 1.
Details") out of the existant 7 elements is enabled and so only this element is
recognized as a link by Watir. The status of this element can be checked by
the following command:
object_enabled = ie.frame("Detail").link(:text,"Step 1. Details").enabled?
The above command returns "True" to say that the element, "Step 1. Details", is
enabled.
But I am not sure how to check the statuses of other elements as Watir does not
recognize them as links because they are disabled. If a similar statement is
used to check the element, "Step 2. Inventors" (which is in a disabled state),
Watir says that it is "unable to find out the object using text and Step 2.
Inventors". The reason behind this, I believe, is that the element, "Step 2.
Inventors" is not identifed as a link as it is in a disabled state (it is not
categorized as a link because it cannot be clicked).
So I am unable to find out the statuses of other elements because I am not sure
what word to put instead of the word "link" in the following checking
statement,
object_enabled = ie.frame("Detail").link(:text,"Step 2. Inventors").enabled?
If I use the word, "element" instead of the word "link" in the above statement,
Watir says "Undefined method 'element' for Watir Frame"
The 'html' of all the disabled items are present as:
Active Element: [TD], Frame: [Detail], Index: [41]
<TD class=tab_disabled_label
background=/iam/images/tab_inactive_bg.png>Step 2. Inventors</TD>
Thanks, in Advance,
Vijay.
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.openqa.org/thread.jspa?threadID=5711&messageID=16393#16393
_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general