I tried in IRB, but I am getting the same exception. I tried with Link also, its giving the same error.
On May 10, 9:15 pm, Tiffany Fodor <tcfo...@comcast.net> wrote: > Hi Vishal! > > The error message you're getting suggests that Watir can't find the > button with id 'showSearchCriteriaButton'. Have you verified that > your browser is on the page you expect and that you get the same error > when you attempt to perform the action in an irb session? > > Sometimes elements that appear as buttons are actually links. Have > you tried the following? > > $ie.link(:text, 'Show Search Criteria').click > > Hope this helps! > > -Tiffany > > On May 10, 4:55 am, Vishal <bvkon...@gmail.com> wrote: > > > > > > > My program it unable to click on Submit button. Below is the Code > > > My code : > > def Click_Show_Criteria > > $ie.button(:id,'showSearchCriteriaButton').click > > end > > > HTML: > > > <TABLE cellpadding=0 cellspacing=0 style='width:100%'><TR > > class='action_button_area'><TD style='width:99%'><BUTTON > > id='hideSearchCriteriaButton' onclick='hideSearchCriteria()'>Hide > > Search Criteria</BUTTON><BUTTON id='showSearchCriteriaButton' > > onclick='showSearchCriteria()' > > onmouseover='showFriendlySearchCriteriaText(this)' > > style='display:none'>Show Search Criteria</BUTTON> <TD > > NOWRAP><DIV NOWRAP id='_datasetNavArea'></DIV><TD style='text- > > align:right' NOWRAP><a id='subSearchNavArea' > > style='display:none;color:black' href='#' onclick='popSearch();return > > false;'><<Back</a> <TD style='text-align:right' NOWRAP><TD > > style='text-align:right' NOWRAP id='optionsArea'><TD style='text- > > align:right' NOWRAP>Group By: <SELECT > > onchange='handleGroupBy(this);'><OPTION m_index='-1'>No > > Grouping<OPTION m_Index='2' m_DateGranularity='1'>Status</SELECT></ > > TABLE> > > > I am getting following error > > > d:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.2/lib/watir/element.rb:52:in > > `assert_ex > > ists': Unable to locate element, using :id, > > "showSearchCriteriaButton" (Watir::E > > xception::UnknownObjectException) > > > -- > > Before posting, please readhttp://watir.com/support. In short: search > > before you ask, be nice. > > > You received this message because you are subscribed > > tohttp://groups.google.com/group/watir-general > > To post: watir-general@googlegroups.com > > To unsubscribe: watir-general+unsubscr...@googlegroups.com > > -- > Before posting, please readhttp://watir.com/support. In short: search before > you ask, be nice. > > You received this message because you are subscribed > tohttp://groups.google.com/group/watir-general > To post: watir-general@googlegroups.com > To unsubscribe: watir-general+unsubscr...@googlegroups.com- Hide quoted text - > > - Show quoted text - -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. You received this message because you are subscribed to http://groups.google.com/group/watir-general To post: watir-general@googlegroups.com To unsubscribe: watir-general+unsubscr...@googlegroups.com