Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7928451
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T19:44:10+00:00 2026-06-03T19:44:10+00:00

I am currently trying to set up WatiN to do some automated testing of

  • 0

I am currently trying to set up WatiN to do some automated testing of a new CRM solution. We have a screen button called Advanced Find.
When this button is clicked, a new pop up opens. This popup has a drop down menu and I would like to click it and select on option from it.

The code for the pop up window is:

td class="ms-crm-AdvFind-Label"><br>
td class="ms-crm-AdvFind-EntityList"> <br>
select name="slctPrimaryEntity" class="ms-crm-SelectBox " id="slctPrimaryEntity"     Sort="ascending" defaultSelected="activitypointer"><br>
option title="Organisations" value="account">

The WatiN code I have is as follows:

ie.Image(Find.ByClass("ms-crm-ImageStrip-advancedfind32")).Click();
IE poppedUpBrowser = IE.AttachTo<IE>(Find.ByTitle("Advanced Find - Microsoft Dynamics CRM"));
SelectList ddl = poppedUpBrowser.SelectList(Find.ByClass("ms-crm-AdvFind-Label")&(Find.ById("slctPrimaryEntity")));<br>
ddl.Option("Organisations").Select();<br>
Assert.That(ddl.SelectedItem.Equals("Organisations"));<br>

Can someone please point out where I have gone wrong.

Thanks.

Edit:

I am currently getting this error message when running the test:

Failure: WatiN.Core.Exceptions.ElementNotFoundException : Could not find OPTION element tag matching criteria: Attribute 'innertext' equals 'Organisations' ignoring case at http://website

Stack Trace:
at WatiN.Core.Element.get_NativeElement()
at WatiN.Core.Element.GetAttributeValueImpl(String attributeName)
at WatiN.Core.Component.GetAttributeValue(String attributeName)
at WatiN.Core.Option.setSelected(Boolean value, Boolean WaitForComplete)
at WatiN.Core.Option.Select()

Edit: More HTML code:

<tbody>
<tr height="100%">
<td class="AdvFind_td_FindBody">
<span id="advancedFind">
<table class="ms-crm-AdvFindControl" id="advFind" cellSpacing="0" cellPadding="0" EntityName="activitypointer" UIProvider="" DataProvider="" EntityTypeCode="4200" DisableValueControlInSimpleMode="0" DistinctFetch="1" SaveChangesAlert="1" IncludeUserQuery="1" IncludeSystemQuery="1" ValidQueryType="0" FilterControlVisible="1" TitleVisible="0" EntityListVisible="1" RelatedEntitiesVisible="1" QueryListVisible="1" CanCreateUserQuery="1" CanWriteUserQuery="1" IncludeAPIQuery="0" FetchMode="2" Buttons="1023" Modes="3" Mode="1" aliasesInInitialFetch="">
<tbody>
<tr class="ms-crm-AdvFind-TitleArea">
<td>
<table class="ms-crm-AdvFind-Title-table" style="table-layout: fixed;">
<tbody>
<tr>
<td>
<table>
<tbody>
<tr>
<td class="ms-crm-AdvFind-EntityList">
<select name="slctPrimaryEntity" class="ms-crm-SelectBox " id="slctPrimaryEntity" Sort="ascending" defaultSelected="activitypointer">
<option title="Activities" value="activitypointer">
<option title="Addresses" value="customeraddress">
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T19:44:11+00:00Added an answer on June 3, 2026 at 7:44 pm

    Is the popup inside a frame. If so, you will need to traverse from the Frame.
    Let me know how it goes.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently trying to set up a new visual studio 2008 solution while
I'm currently trying to set up integration/acceptance testing for a new rails 3 application
I've got a new project, and currently I'm trying to set it correctly. But
I'm currently trying to set up a nice back button contextual menu for my
I am currently trying to set up an nsurlconnection I almost have everything sorted
I'm currently trying to set up a web page for a touch screen computer,
I'm currently trying to set up an iPad web app. I have my home
I'm currently trying to query and set some windows registry entries through a Java
I am new to Joomla, I am currently trying to set up a information
I'm currently trying to build a more or less complete set of unit tests

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.