Expand|Select|Wrap|Line Numbers
- IEWindow.Document.querySelector("div[id=pagecontents] div[class=container] div[id=resultOptions] form[name=resultOptions] select[id=selectResult]").Focus
- IEWindow.Document.querySelector("div[id=pagecontents] div[class=container] div[id=resultOptions] form[name=resultOptions] select[id=selectResult]").selectedIndex = 4
- IEWindow.Document.querySelector("div[id=pagecontents] div[class=container] div[id=resultOptions] form[name=resultOptions] select[id=selectResult]").dispatchEvent evt
I then found another way to find that dropdown, and it appears that it is a control called selectResult (see the HTML below).
Expand|Select|Wrap|Line Numbers
- <div id="page-header">_</div>
- <!-- end of PAGE HEADER -->
- <-- PAGE CONTENTS -->
- <div id="pagecontents">
- <div class="container">
- <div class="panel panel-default scc-scanengine-panel" id="scc-scanengine-criteria">_</div>
- <div id="resultOptions">
- <form name="resultOptions">
- <span class="form-item-label">Available Actions</span>
- <select id="selectResult">
- <option selected="selected" value="none">- Choose -</option>
- <option value="new">Store these results in a new C_</option>
- <option value="merge">Merge these results with an ex_</option>
- <option value="replace">Replace an existing ChartList _</option>
- <option value="csv">Download In CSV Format</option>
- </select>
- </form>
- </div>
- <script type = "text/javascript">,!-- var sortOrder = "USAD"; _</script>
- <form name="submitForm" action="/def/servlet/SC.uscan" method="post">_</form>
- <!-- TABLE DATE ROW -->
- <div class="dt-date-row">_</div>
- </div>
So... The problem is that I am having trouble connecting to the IE control (the dropdown box). Then, when I connect to it, I need to be able to select the csv option (which I'm assuming is option 4 if zero based).
Thoughts?