View Single Post
  #7 (permalink)  
Old March 12th, 2004, 12:24 PM
joefawcett's Avatar
joefawcett joefawcett is offline
Wrox Author
Points: 9,763, Level: 42
Points: 9,763, Level: 42 Points: 9,763, Level: 42 Points: 9,763, Level: 42
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Exeter, , United Kingdom.
Posts: 3,074
Thanks: 1
Thanked 38 Times in 37 Posts
Default

If you have access to the server try this short script, save it to a file and double click. Then try the second version from your machine (if it's not the same one). This will simulate what the sp_OACreate does.
Code:
//Simple COM test, save as ProgIdTest.js on actual server and run from server
try
{
  var oObject = new ActiveXObject("nti.CriminalData");
}
catch(e)
{
  WScript.echo(e.message);
}
oObject = null;
Code:
//Simple COM test, save as ProgIdTest.js on your machine and run from there
try
{
  var oObject = new ActiveXObject("nti.CriminalData", "<server name goes here"); //Server name, not SQL server name. They maybe different
}
catch(e)
{
  WScript.echo(e.message);
}
oObject = null;
If you get 'Cannot create object' or the like the control is not registered on the server.

--

Joe