I have the following function:
<script language="javascript"><!--
function UpdateResult(oList1, inMCLID, inLSID, oLabel)
{
alert(oList1.options[oList
1.selected
Index].val
ue & ", " & inMCLID & ", " & inLSID & ", " & oLable.name)
var sql, RecAffect
var conn = Server.CreateObject("ADODB
.CONNECTIO
N");
conn.Open("Provider=SQLOLE
DB;User ID=ilx;password=webuser!;I
nitial Catalog=LeadsMaster;Data Source=ilx2ksql");
sql = "web_os_UpdateCallResult " & oList1.options[oList1.sele
ctedIndex]
.value &", " & inMCLID & ", " & inLSID;
conn.Execute(sql,RecAffect
);
conn.Close;
if (RecAffect>0) {
oLabel.value = "Updated!";
} else {
oLabel.value = inMCLID;
}
}
//--></script>
Located in the <head> tag of my web page. I have a combo Box I create that is like so with a following Textbox:
<Select id='ResultsCBO1' onchange='UpdateResult(thi
s,987594, 1637, this.form.txtUpdate1);'>
<option Value = 17>Bad Address (Mail Only)</Option>
<option Value = 7>Business phone</Option>
<option Value = 10>Call Back</Option>
<option Value = 5>Disconnected</Option>
<option Value = 1>Do not call</Option>
<option Value = 6>Fax number</Option>
<option Value = 0 SELECTED >Has not been called</Option>
<option Value = 3>Not interested</Option>
<option Value = 4>Not Qualified</Option>
<option Value = 13>NQ Over Age</Option>
<option Value = 16>NQ Owner</Option>
<option Value = 15>NQ Toured Before</Option>
<option Value = 8>Reservation</Option>
<option Value = 12>Spanish Speaking</Option>
<option Value = 14>Wrong Area Code</Option>
<option Value = 11>Wrong Name for Phone</Option>
</Select>
<INPUT disabled readOnly type=text maxLength=10 size=10 Name=txtUpdate1>
why, when I change the value does it not run the Javascript function?
Start Free Trial