[thelist] Intrinsic Constants in JScript?

Gregory.John.Toland at census.gov Gregory.John.Toland at census.gov
Fri Oct 6 17:12:42 CDT 2000


Thanks to Scott and James for the clarity.  One question though.  If I have the
following line in my GLOBAL.ASA file:

     <!-- METADATA TYPE="typelib" FILE="C:\Program Files\Common
Files\System\ADO\msado15.dll"-->

Does this account for the correct ADO constant value whether used within
Javascript or VBScript?  In other words.....

C:\Program Files\Comman Files\System\ADO\ADOVBS.inc has:
     Const adParamInput = &H0001

C:\Program Files\Comman Files\System\ADO\ADOJAVAS.inc has:
     var adParamInput = 0x0001;

Because I am not including the appropriate constant file, but using the METADATA
tag does IIS know to use the correct value inside the <script> tag depending on
whether the language is "Javascript" or "VBScript".  Am I confusing anybody?
Don't mean to.

Greg



From: Scott Dexter <sgd at ti3.com>

      oCmd.CommandType = 4;
>
> If I were to try:
>       oCmd.CommandType = adCmdStoredProc;
>
> I get an error.  Am I to assume the concept of intrinsic
> constants does not
> exist in JScript?

um, that's not an intrinsic constant; you'll find it in adovbs.inc (commonly
found in C:\Program Files\Common Files\System\ado)

hope that helps some
sgd



From: "Aylard JA (James)" <jaylard at equilon.com>

> If I were to try:
>       oCmd.CommandType = adCmdStoredProc;
>
> I get an error.  Am I to assume the concept of intrinsic constants does
not
> exist in JScript?

     Well, you'd get an error in VBScript, too, if you didn't include the
adovbs.inc file (as it is usually called), or otherwise assign the value 4
to the variable adCmdStoredProc. The common equivalent to adovbs.inc for
JavaScript is adojavas.inc, which should be included with your ADO
installation.

hth,
James Aylard







More information about the thelist mailing list