Aarsh Thakur
Aarsh Thakur

Reputation: 607

how to use asp pages in asp.net

I want to use asp page in my asp.net application without any modification in asp pages.

further I want to add master page in my .net application.So i need the changes to be reflected in the asp page also.

is it possible....any how? or any alternative to use this..?

pls suhggest me .....thanx in advance...

Upvotes: 1

Views: 2177

Answers (4)

João Marcus
João Marcus

Reputation: 1608

A dirty way: Make a HTTP request from the ASP.NET code to the .asp page and store the response in a web control. It's not pretty, but it works.

Upvotes: 1

davethecoder
davethecoder

Reputation: 3932

i have used asp and asp.net vb together when i was learning my method was to use jquery to put my asp classic generated html into designated divs... as my leaning increased i needed to use this method less and less its a great way to pick up asp.net C# when moving from a VB background when you dont really have time to learn, like at work.

Upvotes: 1

RuudKok
RuudKok

Reputation: 5302

Classic ASP files run without any problems in a ASP.NET website. As soon as you want to mix classic ASP and ASP.NET functionality in one file you will get errors. Applying master pages to classic ASP files can't be done.

[EDIT]
An alternative could be to rewrite the functionality of the ASP pages into ASP.NET. There is a SO question about tools for converting from ASP to ASP.NET here.

Upvotes: 2

John Saunders
John Saunders

Reputation: 161773

ASP does not have master pages, so you can't use them. The most sensible thing to do is to rewrite the ASP page in ASP.NET, while there are still people around who understand what the ASP page was meant to do. There will otherwise come a time when nobody understands that page.

The closest thing I've seen to what you're looking for is to write an ASP.NET page that refers to the ASP page through an IFRAME. The ASP.NET page can be a content page, referring to the master page, and the ASP page can stay the same.

Upvotes: 2

Related Questions