jscript.dll on .asp page?

Z

zz12

Hello, would anyone be able to confirm that 'jscript.dll' is a necessary
file for an .asp page on IIS 5.0 to use the <script language="JavaScipt"
runat="SERVER"> code? It looks like the code in this section is not working
and being recognized since it keeps giving me:

"Microsoft JScript runtime (0x800A01B0)
File name or class name not found during Automation operation"

and am suspecting that this jscript.dll file is a necessary file that's
missing or not installed since my search on the webserver's c drive came up
empty.

Thanks in advance.
 
E

Evertjan.

zz12 wrote on 20 nov 2007 in microsoft.public.inetserver.asp.general:
Hello, would anyone be able to confirm that 'jscript.dll' is a
necessary file for an .asp page on IIS 5.0 to use the <script
language="JavaScipt" runat="SERVER"> code? It looks like the code in
this section is not working and being recognized since it keeps giving
me:


Testing:

<script language="JavaScipt" runat="SERVER">
var a=1;
</script>

returns:

Active Server Pages error 'ASP 0129'
Unknown scripting language
/test.asp, line 1
The scripting language 'JavaScipt' is not found on the server.
 
D

Dooza

Evertjan. said:
zz12 wrote on 20 nov 2007 in microsoft.public.inetserver.asp.general:



Testing:

<script language="JavaScipt" runat="SERVER">
var a=1;
</script>

returns:

Active Server Pages error 'ASP 0129'
Unknown scripting language
/test.asp, line 1
The scripting language 'JavaScipt' is not found on the server.

Is that cos of the typo?

Steve
 
A

Anthony Jones

zz12 said:
Hello, would anyone be able to confirm that 'jscript.dll' is a necessary
file for an .asp page on IIS 5.0 to use the <script language="JavaScipt"
runat="SERVER"> code? It looks like the code in this section is not working
and being recognized since it keeps giving me:

"Microsoft JScript runtime (0x800A01B0)
File name or class name not found during Automation operation"

and am suspecting that this jscript.dll file is a necessary file that's
missing or not installed since my search on the webserver's c drive came up
empty.

Yes JScript.dll is necessary for any Jscript code to run in ASP, Wscript,
Cscript, Internet Explorer or anything else using the MS script hosting APIs
on the machine.
 
Z

zz12

Would you happen to know where I can download with instructions on how to
install and register this file for Windows 2000 Server? I've looked around
on the web and can't really seem to find how to do this clearly.

Thanks a bunch for your speedy and informative reply Anthony. Much
appreciated.
 
B

Bob Barrows [MVP]

zz12 said:
Hello, would anyone be able to confirm that 'jscript.dll' is a
necessary file for an .asp page on IIS 5.0 to use the <script
language="JavaScipt" runat="SERVER"> code? It looks like the code in
this section is not working and being recognized since it keeps
giving me:

"Microsoft JScript runtime (0x800A01B0)
File name or class name not found during Automation operation"

and am suspecting that this jscript.dll file is a necessary file
that's missing or not installed since my search on the webserver's c
drive came up empty.
Given the wording of the error message, I strongly suspect that the
jscript.dll file is installed an running, otherwise it would not have
supplied a runtime error. I suspect protected or system files, set by
default in Windows Explorer to be hidden, do not show up in your search.

I would look to the code inside the script block for the problem. Time
to do some debugging - comment out all the code in the block and see if
you still get the error. Then uncomment lines until you find the one
that generates the error.
 
Z

zz12

Yes you are correct. I unhid the system files and then did notice 'jscript.dll' was there. I even confirmed registering it and it still gives me the same error message. I wonder why it works from the original developer's environment in which ours is the same. The only difference is that the programmer uses a .udl file as the main datasource in which the authentication settings are slightly different and confirm the 'Test Connection' button from this .udl file is succeeding. I don't know if this helps but the following is the section of the code which I adjusted slightly to get to the point with different namings which is giving me the error:

<script language="JavaScript" runat="SERVER">
function GetDataTest(database){
var connection;

connection= new ActiveXObject("ADODB.Connection");
connection.Open(database); //<---- Here is the line that is returning the 'Microsoft JScript runtime (0x800A01B0)' error message.
Much thanks Bob.
 
B

Bob Barrows [MVP]

zz12 said:
Yes you are correct. I unhid the system files and then did notice
'jscript.dll' was there. I even confirmed registering it and it
still gives me the same error message. I wonder why it works from
the original developer's environment in which ours is the same. The
only difference is that the programmer uses a .udl file as the main
datasource in which the authentication settings are slightly
different and confirm the 'Test Connection' button from this .udl
file is succeeding. I don't know if this helps but the following is
the section of the code which I adjusted slightly to get to the point
with different namings which is giving me the error:

<script language="JavaScript" runat="SERVER">
function GetDataTest(database){
var connection;

connection= new ActiveXObject("ADODB.Connection");
connection.Open(database); //<---- Here is the line that is
returning the 'Microsoft JScript runtime (0x800A01B0)' error message.
Much thanks Bob.

I would not use "connection" for the name of a variable ... it's too
close to being the name of an actual object. It's probably not the
source of your error but I would suggest using "cn" or "conn" for your
variable name, rather than "connection"

Given that you've changed the variable name and the error still occurs,
I have to say that a call to the Open method will never result in an
Automation error. It has to be the previous line. Again ... you can
confirm this by commenting out everything except that line. Given that
you are able to confirm my hypothesis, it is likely that your machine
has a defective MDAC installation.

Oh, wait. I never do ADO code in javascript. Can one of you javascript
users confirm whether using "Open" as opposed to "open" could cause the
error?
 
Z

zz12

Yes I temporarily changed the 'connection' name to a generic one just for
this debugging help group purpose.

I did change the 'Open' to 'open' and it still gives me the same error. I
guess I'll try to debug in seeing what the line above for 'connection' value
is set at (if it's even being set and/or holding it). Since this is jscript
and I'm more of a vbscript guy would anyone happen to know off the top of
one's head in how to debug similar to a 'response.write' line in jscript?

I think you're hot on the trail on this Bob. Thank you very much for your
input and expertise :)
 
B

Bob Barrows [MVP]

zz12 said:
Yes I temporarily changed the 'connection' name to a generic one just
for this debugging help group purpose.

I did change the 'Open' to 'open' and it still gives me the same
error. I guess I'll try to debug in seeing what the line above for
'connection' value is set at (if it's even being set and/or holding
it). Since this is jscript and I'm more of a vbscript guy

That means you can try testing vbscript code that does the same thing,
can't you?

Do this: create a page that contains nothing but the following code and
test it:

<script language="JavaScript" runat="SERVER">
var connection;
connection= new ActiveXObject("ADODB.Connection");
</script>
..
Does this produce the error?
would
anyone happen to know off the top of one's head in how to debug
similar to a 'response.write' line in jscript?

The Response object is provided by the ASP engine so response.write
works in both vbscript and javascript.
 
Z

zz12

I created an .asp page that contains only the following like you recommended:

<script language="JavaScript" runat="SERVER">
var connection;
connection= new ActiveXObject("ADODB.Connection");
</script>

and surprisingly it it didn't give me an error message. It just shows a blank page which looks like a good thing in that the jscript.dll is working?

Thanks again for your efforts Bob. This is really helping me out and learning something new.
 
B

Bob Barrows [MVP]

OK, next step is to add in a connection.open statement utilizing a
connection string that you know will work.
 
Z

zz12

I think I have it working now.

Thanks so much Bob and all for all of your helpful and speedy replies.
Totally appreciate it.

Take cares, you guys are awesome :)
 
D

Dave Anderson

Bob said:
Oh, wait. I never do ADO code in javascript. Can one of you javascript
users confirm whether using "Open" as opposed to "open" could cause
the error?

Don't know about javascript, but for JScript, .Open() is correct.

Incidentally, there are no reserved words or other objects in ASP/JScript
named "connection" or "Connection".
 
Z

zz12

I had these working on a w2k server (iis 5.0) and am now trying to run these on a w2k3 server (iis 6.0) and am getting the following error:

Microsoft JScript runtime error '800a01b0'
File name or class name not found during Automation operation
Would anyone know if there's a security setting or something that I'm missing in why the above error message shows on the w2k3 server when it was running fine on the w2k server?

Thanks in advance.
 

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,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top