Server.Create Object Failed error

2.5k views Asked by At

I am debugging some old ASP code and have stumbled upon the following error:

Server.CreateObject Failed

Here's the line of code where I got the error:

Set Session("SessionBoolian") = Server.CreateObject("DBUtils.SQLExpression")

Where is DBUtils.SQLExpression located? I can't seem to find a reference to it in the code. How is it set?

I do have a DBUtils.dll in my bin folder, is there a way to look inside a DLL to find out if there's a SQLEXpression method there?

2

There are 2 answers

0
Abbas On BEST ANSWER

DBUtils.SQLExpression is most probably an ActiveXDLL. Your best bet is to search for the DBUtils.dll or DBUtils.SQLExpression.dll file.

If it's available, you may need to register it to the COM server using regsvr32 i.e. type regsvr32 D:\MyPath\DBUtils.dll in the run dialog and press enter.

You may also want to do a bit of error handling before setting an ActiveXObject in the session and see exactly what is the error. Something like this:

Dim sqlExpression
sqlExpression = Nothing

On Error Resume Next
Set sqlExpression = Server.CreateObject("DBUtils.SQLExpression")

If Err.Number <> 0 then
    Response.Write "#: " & Err.Number & ", Source: " & Err.Source & ", Description: " & Err.Description
Else
    'Rest of your code
End If
0
Reporter On

It seem that is a third party active-x plugin. Your posted code snippet creates an instanz of that and saves into a seesion with attribute 'SessionBoolian'.