There is text label on a webpage, and I am trying to click on that to
open a pop-up window,but not getting opened. here is the HTML code:

  <td width="40%">
    <div id="EmpId.outline">
    <input type="hidden" name="EmpId" value="" id="popupEmpId">
    <input type="text" name="EmpCode" value="" readonly="readonly"
class="textMedium250" id="popupEmpCode" autocomplete="off"> <a
href="#f2"><label  onclick="checkForPopup('EmpPopupDiv','Select a
Emp',640,true,refreshConditionOptions);"> + Search for a Emp</label>
</a>
     </div>
  </td>

I have to click on the field + Search for a Emp, but could not do
that.

I'm sorry, this is Ruby forum. You may be looking for JavaScript/DHML one.

To answer your question, your JavaScript call may be invalid. The last variable 'refreshConditionOptions' is a global variable from somewhere?

No i extract the html above from a webpage - onto which i am creating a web automation script.but i am not able to click on the "labeled link", thus couldn't proceed further. I am using "selenium" with Ruby 1.9.3.

Thanks,

OK, then I need to see your raw page (HTML+Ruby). You need to look at the part where :onclick=>"..." and ensure that the it concatenate the variable.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.