Object Expected Error

C

crjunk

I'm receiving an "Object Expected" Error (Line:28, Char:7). I'm
confused as to what is happening. I have virtually the same exact
function in a different web page and I do not receive an error with
this other page. Also, if I run this code in Fire Fox, I do not
receive any error. Is there something that I'm missing? The error is
pointing to "TextChanged();".
Here is my code below:

<!-- Generated by Webspeed: http://www.webspeed.com/,
http://www.possenet.org/ -->

<HTML>
<HEAD>
<TITLE> Maintain MPR </TITLE>
<script type="text/javascript" language="JavaScript">
<!--
function blockNumbers(e)
{
var key;
var keychar;
var reg;
if(window.event) {
// for IE, e.keyCode or window.event.keyCode can be
used
key = e.keyCode;
}
else if(e.which) {
// netscape
key = e.which;
}
else {
// no event, so pass through
return true;
}
keychar = String.fromCharCode(key);
reg = /[0-9.]/ ;
if (reg.test(keychar)) {
TextChanged();
}
return reg.test(keychar);
}
//-->
</script>
</HEAD>
<BODY>
<form name="ScheduleForm" Method="Post">
<table border="1" width="50%" cellpadding ="3" cellspacing="0">
<tr>
<td bgcolor=#"008000" width="80%"><font face="Arial"
color="#FFFFFF" size ="3"><B>Enter 4-Digit Class Code: </b></font></td>
<td bgcolor="#ffffcc" align="center"><input type="text"
width="20%" name="txtClassCode" size="5" onkeypress="return
blockNumbers(event)"/>
</tr>
<tr>
<td colspan="2" align="center" bgcolor="#666666"><input
NAME="SendRequest" TYPE="Submit" value="Find Code" >&nbsp;<input
type="submit" value="Back To Policy" name="SendRequest"></td>
</tr>
</table>
</form>
</BODY>
</HTML>

Can anyone tell me what is going on?

Thanks,
CR Junk
 
V

VK

crjunk said:
I'm receiving an "Object Expected" Error (Line:28, Char:7). I'm
confused as to what is happening. I have virtually the same exact
function in a different web page and I do not receive an error with
this other page. Also, if I run this code in Fire Fox, I do not
receive any error. Is there something that I'm missing? The error is
pointing to "TextChanged();".
Here is my code below:

<!-- Generated by Webspeed: http://www.webspeed.com/,
http://www.possenet.org/ -->

<HTML>
<HEAD>
<TITLE> Maintain MPR </TITLE>
<script type="text/javascript" language="JavaScript">
<!--
function blockNumbers(e)
{
var key;
var keychar;
var reg;
if(window.event) {
// for IE, e.keyCode or window.event.keyCode can be
used
key = e.keyCode;
}
else if(e.which) {
// netscape
key = e.which;
}
else {
// no event, so pass through
return true;
}
keychar = String.fromCharCode(key);
reg = /[0-9.]/ ;
if (reg.test(keychar)) {
TextChanged();
}
return reg.test(keychar);
}
//-->
</script>
</HEAD>
<BODY>
<form name="ScheduleForm" Method="Post">
<table border="1" width="50%" cellpadding ="3" cellspacing="0">
<tr>
<td bgcolor=#"008000" width="80%"><font face="Arial"
color="#FFFFFF" size ="3"><B>Enter 4-Digit Class Code: </b></font></td>
<td bgcolor="#ffffcc" align="center"><input type="text"
width="20%" name="txtClassCode" size="5" onkeypress="return
blockNumbers(event)"/>
</tr>
<tr>
<td colspan="2" align="center" bgcolor="#666666"><input
NAME="SendRequest" TYPE="Submit" value="Find Code" >&nbsp;<input
type="submit" value="Back To Policy" name="SendRequest"></td>
</tr>
</table>
</form>
</BODY>
</HTML>

Can anyone tell me what is going on?

Thanks,
CR Junk


So yes, where is the function TextChanged() you're calling? It's not on
this page. There must be a .js library you did not include or you
deleted it by mistake.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top