Solved

Can I include asp page in Asp.net page (.aspx)? How?

Posted on 2004-08-18
9
433 Views
Last Modified: 2013-11-18
I have the following file in asp

<!-- #include virtual="/Common/ESW_PWD/oESWInc.asp" -->

Can i include in asp.net page (aspx)

Then where should I include and what is Syntax

Thanks
0
Comment
Question by:jra2002
9 Comments
 
LVL 28

Expert Comment

by:mmarinov
ID: 11830276
the answer is NO


but you can insert in aspx page ascx file which is User Control
http://msdn.microsoft.com/library/en-us/vbcon/html/vbtskaddingusercontrolstowebformspage.asp

Regards,
B..M
0
 
LVL 17

Expert Comment

by:AerosSaga
ID: 11830385
To  expand on mmarinov's post you create a user control, which is much like an old school includes.  In that User Control you can embed you existing asp.  So its kind of a work around to do what you want.  You just have to think about it a little differently in .NET.

Regards,

Aeros
0
 

Author Comment

by:jra2002
ID: 11830634
Can you send me some sample code.

Because in the current project which is in .net I have to use the common code which is in classic asp

Thanks
0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 17

Expert Comment

by:AerosSaga
ID: 11830659
Well really you already have the code, just open Visual Studio and Create a New User control.  Paste the asp into the html of the user control, then drag your user control onto your webform; .aspx page where you want it to be rendered.

Regards,

Aeros
0
 

Author Comment

by:jra2002
ID: 11831418
<!-- #include virtual="/Common/ESW_PWD/oESWInc.asp" -->

I think some syntax error is there. When I do like this then I am getting the above line as a comment line
0
 
LVL 17

Expert Comment

by:AerosSaga
ID: 11831479
don't put the include line in the user control put the acutal asp from the include file.
0
 

Author Comment

by:jra2002
ID: 11834451
I had developed the .Net component to fix this problem. It works
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 12117264
PAQed, with points refunded (20)

Computer101
E-E Admin
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most of the sites are being standardized with W3C Web Standards. W3C provides lot of web standard services to the web. They have the web specification, process and documentation for all the web standards. You can apply HTML, CSS and Accessibility st…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question