How to specify physical path in ASPX page?

Posted by salvationishere on Stack Overflow See other posts from Stack Overflow or by salvationishere
Published on 2010-05-22T18:58:19Z Indexed on 2010/05/22 19:11 UTC
Read the original article Hit count: 212

I am developing a C# VS 2008 / SQL Server 2008 ASP.NET Web Applications project. In one of my ASPX files I am trying to reference the Master file, which is actually located in the parent website. In other words, when I open the parent website, I see this project listed. But when I open this project separately, I do not see parent website and this project is the root.

So now how do I use the Master file from the parent website? Currently, I have in my ASPX file:

<%@ Page Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeFile="EnhancedCreateUserWizard.aspx.cs"
    Inherits="Membership_EnhancedCreateUserWizard" Title="Untitled Page" %>

But this won't work because it is a virtual path and since this project is the root, I can't access the Master file virtually. Instead I want to specify physical path. How accomplish I do this?

© Stack Overflow or respective owner

Related posts about c#

Related posts about visual-studio-2008