473,396 Members | 2,082 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

How do I use a mouse click to select a particular dropdown option?

Hi, Thanks in advance to for the help!!!!!

When the page loads, "Application Inventory" is selected by default ---
I want to use a mouse.click to select "Systems Compliance",
BUT HOW?
I'm clueless as I don't write javascript, but would really appreciate the assistance. Thanks a MILLION!

[HTML]<script language="javascript" type="text/javascript">
<!--
function __doPostBack(eventTarget, eventArgument) {
var theform;
if (window.navigator.appName.toLowerCase().indexOf("m icrosoft") > -1) {
theform = document.CriteriaBar;
}
else {
theform = document.forms["CriteriaBar"];
}
theform.__EVENTTARGET.value = eventTarget.split("$").join(":");
theform.__EVENTARGUMENT.value = eventArgument;
theform.submit();
}
// -->
</script>

<table cellSpacing="0" cellPadding="2" width="100%" border="0">
<tr>
<td noWrap align="center"><span class="ReportSelectLabel">Select Report</span>
</td>
</tr>
<tr>
<td>
<select name="_ddlReports" onchange="javascript:OnChange();__doPostBack('_ddl Reports','')" language="javascript" id="_ddlReports" class="ReportSelect" style="height:24px;width:100%;">
<option selected="selected" value="Application Inventory">Application Inventory</option>
<option value="Computer Inventory">Computer Inventory</option>
<option value="Failed System Scans">Failed System Scans</option>
<option value="Installed Patches By Product">Installed Patches By Product</option>
<option value="Installed Patches By Severity">Installed Patches By Severity</option>
<option value="Missing Patches">Missing Patches</option>
<option value="Missing Patches By System">Missing Patches By System</option>
<option value="Missing Patches By Severity">Missing Patches By Severity</option>
<option value="Missing Patches Detailed">Missing Patches Detailed</option>
<option value="Missing Patches Summary">Missing Patches Summary</option>
<option value="New Patches">New Patches</option>
<option value="Patch Analysis">Patch Analysis</option>
<option value="Patch Details">Patch Details</option>
<option value="Patch History">Patch History</option>
<option value="Patch Signature">Patch Signature</option>
<option value="Patch Status Summary">Patch Status Summary</option>
<option value="Policy Compliance">Policy Compliance</option>
<option value="Policy Coverage">Policy Coverage</option>
<option value="Policy Details">Policy Details</option>
<option value="Pushed Patches">Pushed Patches</option>
<option value="Severity Dynamics">Severity Dynamics</option>
<option value="Scan Dynamics">Scan Dynamics</option>
<option value="Systems Compliance">Systems Compliance</option>
<option value="Verify Installed Patches">Verify Installed Patches</option>

</select>[/HTML]
Aug 20 '07 #1
2 2069
vituko
48
<option selected="selected" value="Application Inventory">Application Inventory</option>

selected="selected"!!!! The option which has this attribute would be the selected by default.

Any way if you want to simulate an event :

createEventObject / createEvent and dispatchEvent / fireEvent
Aug 20 '07 #2
acoder
16,027 Expert Mod 8TB
Please use CODE tags when posting code. Thanks.

Also, use a good thread title. Thanks!
Aug 20 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Bernard Philip | last post by:
hey everybody i have a dropdown list opening a window, ie <SELECT onchange=openwindow()..> <OPTION value=.... <..choice1..> <..choice2..> when clicking on an choice if i clear this window,...
4
by: Xerxes | last post by:
Hi, can I have a field automatically clicked by calling something like click()? I have a dropdown box, one of whose elements is "Others (Please Specify)". I list the dropdown boxes values...
5
by: Charles Law | last post by:
Sorry for reposting this question, but I did not get a single answer last time, and I'm sure you guys must have some thoughts on the matter. I have a user control which can be dragged and dropped...
2
by: Monty | last post by:
I use a SELECT dropdown as the nav interface for jumping to a chosen page number. When I setup up the SELECT element on the page, I want to show the user the current page number they are on, so, I...
3
by: cover | last post by:
Is it possible to use a 'mouse up' click in forms where if you have for example, a drop down menu where you might click as the top selection, an equipment area (hard coded into the form), the type...
1
by: Andy Baxter | last post by:
hello, I'm writing a panoramic image viewer in javascript. When the mouse is over the image, I want it to be a crosshair (over most of the image), or a hand/pointer (when it's over an image map...
3
by: Morten Snedker | last post by:
If I have a number of random applications open, move the mouse cursor to a given position and do a click, the application gets the focus. That is what this simple code should illustrate: Dim...
1
by: Sri Nanduri | last post by:
Hi , I am new to JS. Please help me to resolve my issue. 1.When the form loads there are two DropDown boxes and a ADD button. 2.When I click the add button it will add two DropDown boxes and a add...
1
by: RichardR | last post by:
I have a webpage which has a table that contains a column with several drop down boxes (<SELECT>). The contents of the drop down boxes are dynamically populated so I have no idea what the actually...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.