Site as virtual directory

L

Lintie

Hi,

I have 2 websites. Now I want to run one site as a virtual site of the
other in IIS 5 (Win 2000).

Like this :
Website 1
\--Website 2 (Virtual directory)

1) If I create the virtual directory and don't create an application
on it, I get the following error:

Description: An error occurred during the parsing of a resource
required to service this request. Please review the following specific
parse error details and modify your source file appropriately.

Parser Error Message: Could not load type 'BoekenB2C.Transport'.
Source Error:
Line 1: <%@ Page language="c#" Codebehind="Transport.aspx.cs"
AutoEventWireup="false" Inherits="BoekenB2C.Transport"
Culture="NL-nl"%>
Line 2: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"Line 3: <HTML>

2) If I create a application on the virtual directory, it works, but
my session is lost.

The only solution I heve yet found is rewriting all the code to not
use code behind, but this is not an option for me. Is there any other
solution?

Thanks in advance,

Patrick
 
G

Guest

Lintie,

Be sure that you have placed your website2 DLL file into the website1 BIN
folder. Because you don't have website2 as an application, it is using
website1 as the application root, and not finding the DLL file to load type
BoekenB2C.Transport.

Also, if you want to maintain website2 as its own application, you can
transfer the session between applications using the following solution
(assuming same domain between applications 1 and 2):
http://www.iansuttle.com/articles/sessiontransfer.aspx
If you do use this, just replace the code in the ASP Classic page to be done
in ASP.Net.

I recommend using the first solution however, as this will keep both
projects within the same session.

Regards,
Ian Suttle
http://www.IanSuttle.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,902
Latest member
Elena68X5

Latest Threads

Top