[Webinar] Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 440
  • Last Modified:


I have a classic ASP web site that I want to migrate into a new ASP.net 3.5 site.   I first created a new ASP.net web site in VS2008.  According to MS, I can run the two sites side by side.  I think MS called this a horizontal installation.    I started to copy the Classic ASP pages to the new site.   and tried opening the ASP home page.  

When I try to open the home page, I get the error - required Object:Server.  It appears to be failing on the line of VBScript code:

  Set  cnn = Server.CreateObject("ADODB.Connection")

Two questions.

1)  How can I resolve this error?

2)  Do know of any link that explains how to migrate a Classic ASP site to an ASP.NEt 3.5 web site keeping the original ASP code?

Thanks for your help.
  • 3
  • 2
1 Solution
Bob LearnedCommented:
It is tough to know whether this question came before or after this post:


Were any of the comments helpful?  Are you still at a loss for a solution?  The problem of ASP classic and ASP.NET has long plagued the web developer.
deepPowdahAuthor Commented:
Thanks for your inquiry.  I actually started with ASP.net.  THen I would see if Experts Exchange had any more information.  

So far I'm still wallowing in the mud.

Craig WagnerSoftware ArchitectCommented:
Create a new Visual Studio Web Application (not Site) project.

Copy your ASP side into the new folder structure.

Click on the Show All Files button in the Solution Explorer.

Right-click on each ASP file and folder in the old site and select "Include in Project"

That should accomplish the basics of getting the ASP code into an ASP.NET project. Now you can start adding ASP.NET WebForms to the project as you wish.

From the error you're getting it almost sounds like you may have renamed the .asp files to .aspx. Don't do that.

Another option would be to make use of the ASP to .NET compiler available here...

Nothing ever in the clear!

This technical paper will help you implement VMware’s VM encryption as well as implement Veeam encryption which together will achieve the nothing ever in the clear goal. If a bad guy steals VMs, backups or traffic they get nothing.

deepPowdahAuthor Commented:
Thanks for your reply and I will try your resolution.  But first I want to isolate what appears to be the critical issue (at least the immediate issue).  I created a web site in VS2008 and copied all the files from my Classic ASP web site (the original web site was running on a WIndowsXP box).  When I try to open it as a Classic ASP web site, i.e http://localhost/WebSite folder, I get the object required: Server message in the following line of code

   set cnn = server.createObject(ADODB.Connection)

So how can I get the system to recognize "server?"

Craig WagnerSoftware ArchitectCommented:
First, you should be creating a Web Application, NOT a Web Site. That's probably part of the problem.

Are you using IIS or Cassini (the built-in web server)? Cassini can't serve up ASP pages.

My guess is it's trying to interpret the page as a .NET page and not handing it off to the ASP handler. There could be many reasons for that. I think recreating the project correctly should be your first step.
deepPowdahAuthor Commented:

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now