469,282 Members | 1,888 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,282 developers. It's quick & easy.

Object does not support this property or method.

I get the following error message on a line that attempts to create an
instance of an ADODB connection object.

"Object does not support this property or method: 'Server.CreateObject' ".

Now the strange thing is that other websites on that server work just fine.
Also, this website is hosted across three machines for load-balancing
purposes - the other websites are kept in sync using a tool that we have and
the files are identical across all three machines. Yet, we get this error on
only one machine.

If all the websites were having trouble I would suspect an update to the
MDAC. If all three machines were facing problems I would suspect a code
change of some sort. But the situation that I have I cannot figure out.

If anyone out there has any ideas I would greatly appreciate the assistance.

TIA,

Rohan
Jul 19 '05 #1
10 3927
> I get the following error message on a line that attempts to create an
instance of an ADODB connection object.

"Object does not support this property or method: 'Server.CreateObject' ".


Can you show the actual line?

--
http://www.aspfaq.com/
(Reverse address to reply.)
Jul 19 '05 #2
Yes.

set con = Server.CreateObject("ADODB.Connection")

This is the line where it fails.

Thanks,

Rohan
"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:eP**************@TK2MSFTNGP09.phx.gbl...
I get the following error message on a line that attempts to create an
instance of an ADODB connection object.

"Object does not support this property or method: 'Server.CreateObject'
".
Can you show the actual line?

--
http://www.aspfaq.com/
(Reverse address to reply.)

Jul 19 '05 #3
We need to see more code. (no html please)

Has it ever worked?

Rohan Hattangdi wrote:
Yes.

set con = Server.CreateObject("ADODB.Connection")

This is the line where it fails.

Thanks,

Rohan
"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:eP**************@TK2MSFTNGP09.phx.gbl...
I get the following error message on a line that attempts to create
an instance of an ADODB connection object.

"Object does not support this property or method:
'Server.CreateObject' ".


Can you show the actual line?

--
http://www.aspfaq.com/
(Reverse address to reply.)


--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Jul 19 '05 #4
Did you try without the Server prefix?

Did you try reinstalling MDAC (not necessarily an upgrade, but more of a
repair)?

--
http://www.aspfaq.com/
(Reverse address to reply.)


"Rohan Hattangdi" <Ro****************@hotmail.com> wrote in message
news:u6**************@TK2MSFTNGP10.phx.gbl...
Yes.

set con = Server.CreateObject("ADODB.Connection")

This is the line where it fails.

Thanks,

Rohan
"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:eP**************@TK2MSFTNGP09.phx.gbl...
I get the following error message on a line that attempts to create an
instance of an ADODB connection object.

"Object does not support this property or method:
'Server.CreateObject' ".

Can you show the actual line?

--
http://www.aspfaq.com/
(Reverse address to reply.)


Jul 19 '05 #5
Sure. Code is below. This code had been working for quite some time and then
it stopped for a bit. It seems however that the problem is always solved
during our nightly IIS resets. Naturally this is not a good way of fixing
things ... BTW, some names have been changed below ...

dim con

dim DSN

dim cmd

dim objCMD

dim POutCon

dim JSCon

sub PunchoutConnection(rs,sql)

set POutCon = Server.CreateObject("ADODB.Connection")

POutCon.Open "File Name=C:\aigi\yyyyy.udl;"

set rs = POutCon.Execute(sql)

end sub

sub Job_Scheduler(rs,sql)

set JSCon = Server.CreateObject("ADODB.Connection")

JSCon.Open "File Name=C:\aigi\Job_Scheduler.udl;"

set rs = JSCon.Execute(sql)

end sub

set con = Server.CreateObject("ADODB.Connection")

'DSN = "DSN=udlAAAAAmsp;uid=xxxxxx;pwd=xxxxxx;"

con.ConnectionTimeout=500

'con.Open DSN

'con.Open "File Name=C:\aigi\udlAAAAAmsp.udl;"

con.Open "File Name=C:\aigi\aaaaaa.udl;"

"Bob Barrows [MVP]" <re******@NOyahoo.SPAMcom> wrote in message
news:OD**************@TK2MSFTNGP11.phx.gbl...
We need to see more code. (no html please)

Has it ever worked?

Rohan Hattangdi wrote:
Yes.

set con = Server.CreateObject("ADODB.Connection")

This is the line where it fails.

Thanks,

Rohan
"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:eP**************@TK2MSFTNGP09.phx.gbl...
I get the following error message on a line that attempts to create
an instance of an ADODB connection object.

"Object does not support this property or method:
'Server.CreateObject' ".

Can you show the actual line?

--
http://www.aspfaq.com/
(Reverse address to reply.)


--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.

Jul 19 '05 #6
Have not tried without Server prefix ...

The MDAC thing - would that not affect every website on that box?

Thanks,

Rohan

"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:O9*************@TK2MSFTNGP09.phx.gbl...
Did you try without the Server prefix?

Did you try reinstalling MDAC (not necessarily an upgrade, but more of a
repair)?

--
http://www.aspfaq.com/
(Reverse address to reply.)


"Rohan Hattangdi" <Ro****************@hotmail.com> wrote in message
news:u6**************@TK2MSFTNGP10.phx.gbl...
Yes.

set con = Server.CreateObject("ADODB.Connection")

This is the line where it fails.

Thanks,

Rohan
"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:eP**************@TK2MSFTNGP09.phx.gbl...
> I get the following error message on a line that attempts to create an > instance of an ADODB connection object.
>
> "Object does not support this property or method:

'Server.CreateObject'
".

Can you show the actual line?

--
http://www.aspfaq.com/
(Reverse address to reply.)



Jul 19 '05 #7
> The MDAC thing - would that not affect every website on that box?

If you reinstall the same version?
Jul 19 '05 #8
No, I mean ... would not an error with the MDAC affect every single website
on that box?

"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
The MDAC thing - would that not affect every website on that box?


If you reinstall the same version?

Jul 19 '05 #9
Maybe, are you saying that this error only happens on one web site, but not
on the others? Have you considered deleting the web site from IIS, and
re-creating it?

--
http://www.aspfaq.com/
(Reverse address to reply.)


"Rohan Hattangdi" <Ro****************@hotmail.com> wrote in message
news:OP**************@TK2MSFTNGP11.phx.gbl...
No, I mean ... would not an error with the MDAC affect every single website on that box?

"Aaron [SQL Server MVP]" <te*****@dnartreb.noraa> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
The MDAC thing - would that not affect every website on that box?


If you reinstall the same version?


Jul 19 '05 #10
Before doing anything drastic, check to make sure that you don't have a
variable named "server" in your code somewhere. That could cause you to see
the error you're seeing. IE,

Dim server, z
set server = createobject("scripting.filesystemobject")
set z = server.createobject("adodb.connection")
set z= nothing
set server = nothing

Ray at home

"Rohan Hattangdi" <Ro****************@hotmail.com> wrote in message
news:e0**************@TK2MSFTNGP10.phx.gbl...
I get the following error message on a line that attempts to create an
instance of an ADODB connection object.

"Object does not support this property or method: 'Server.CreateObject' ".

Now the strange thing is that other websites on that server work just fine. Also, this website is hosted across three machines for load-balancing
purposes - the other websites are kept in sync using a tool that we have and the files are identical across all three machines. Yet, we get this error on only one machine.

If all the websites were having trouble I would suspect an update to the
MDAC. If all three machines were facing problems I would suspect a code
change of some sort. But the situation that I have I cannot figure out.

If anyone out there has any ideas I would greatly appreciate the assistance.
TIA,

Rohan

Jul 19 '05 #11

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

7 posts views Thread by Martin Robins | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.