4

When using classic ASP, what is the difference between declaring connection via object tag:

<object RUNAT="Server" ID="cn" PROGID="ADODB.Connection"></object> 

and declaring the connection via the Server.CreateObject() call:

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

Or is there any difference? Performance, memory, etc..

Joel Coehoorn
  • 399,467
  • 113
  • 570
  • 794
slolife
  • 19,520
  • 20
  • 78
  • 121

1 Answers1

1

The object method should perform better, because the object is first created when you start using it.

I found some articles, maybe they give you some insight:

http://www.aspmessageboard.com/showthread.php?t=6775

http://www.asp101.com/tips/index.asp?id=4

BenMorel
  • 34,448
  • 50
  • 182
  • 322
vLX
  • 103
  • 6