Khorvat,
Since this was getting confusing, I started from the first step...fresh installation.
Then I have copied Default.cs and designer file from " GitHub"
Then I pasted the default.cs and designer file in my solution portal.
Now without even touching the default.cs code when I try to rebuilt and run I get WHOOPS error and I see this in log
2013-01-24 09:26:08,254 [10] ERROR MonoX [BaseHttpApplication] - Application Error
System.Web.HttpParseException (0x80004005): The type 'MonoSoftware.MonoX.Pages.Default' is ambiguous: it could come from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\ProjectName.Web.DLL' or from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\MonoX.DLL'. Please specify the assembly explicitly in the type name. ---> System.Web.HttpParseException (0x80004005): The type 'MonoSoftware.MonoX.Pages.Default' is ambiguous: it could come from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\ProjectName.Web.DLL' or from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\MonoX.DLL'. Please specify the assembly explicitly in the type name. ---> System.Web.HttpException (0x80004005): The type 'MonoSoftware.MonoX.Pages.Default' is ambiguous: it could come from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\ProjectName.Web.DLL' or from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\MonoX.DLL'. Please specify the assembly explicitly in the type name.
at System.Web.UI.Util.GetTypeFromAssemblies(IEnumerable assemblies, String typeName, Boolean ignoreCase)
at System.Web.UI.TemplateParser.GetType(String typeName, Boolean ignoreCase, Boolean throwOnError)
at System.Web.UI.TemplateParser.ProcessInheritsAttribute(String baseTypeName, String codeFileBaseTypeName, String src, Assembly assembly)
at System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary parseData)
at System.Web.UI.TemplateParser.ProcessException(Exception ex)
at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding)
at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding)
at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding)
at System.Web.UI.TemplateParser.ParseReader(StreamReader reader, VirtualPath virtualPath)
at System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath)
at System.Web.UI.TemplateParser.ParseInternal()
at System.Web.UI.TemplateParser.Parse()
at System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType()
at System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider)
at System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders()
at System.Web.Compilation.BuildProvidersCompiler.PerformBuild()
at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath)
at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
at System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound)
at System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp)
at System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath)
at System.Web.UI.PageHandlerFactory.System.Web.IHttpHandlerFactory2.GetHandler(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath)
at System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig)
at System.Web.HttpApplication.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
My Default.aspx.cs is this: (just like I downloaded from " GitHub" - no modifications)
using System;
using System.Linq;
namespace MonoSoftware.MonoX.Pages
{
public partial class Default : BasePage
{
}
}
In my RewrittenPaths.tt I changed this as you suggested:
From
static string RootFolder;
static string defaultNamespace = "MonoSoftware.MonoX";
To
static string RootFolder;
static string defaultNamespace = "MonoSoftware.MonoX.Pages";
(match with namespace in default.cs)
I get this error in log:
2013-01-24 09:30:59,597 [10] ERROR MonoX [BaseHttpApplication] - Application Error
System.Web.HttpParseException (0x80004005): The type 'MonoSoftware.MonoX.Pages.Default' is ambiguous: it could come from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\MonoX.DLL' or from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\ProjectName.Web.DLL'. Please specify the assembly explicitly in the type name. ---> System.Web.HttpParseException (0x80004005): The type 'MonoSoftware.MonoX.Pages.Default' is ambiguous: it could come from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\MonoX.DLL' or from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\ProjectName.Web.DLL'. Please specify the assembly explicitly in the type name. ---> System.Web.HttpException (0x80004005): The type 'MonoSoftware.MonoX.Pages.Default' is ambiguous: it could come from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\MonoX.DLL' or from assembly 'C:\Users\PC\Desktop\MonoX-Sol-Custom\bin\ProjectName.Web.DLL'. Please specify the assembly explicitly in the type name.
at System.Web.UI.Util.GetTypeFromAssemblies(IEnumerable assemblies, String typeName, Boolean ignoreCase)
at System.Web.UI.TemplateParser.GetType(String typeName, Boolean ignoreCase, Boolean throwOnError)
at System.Web.UI.TemplateParser.ProcessInheritsAttribute(String baseTypeName, String codeFileBaseTypeName, String src, Assembly assembly)
at System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary parseData)
at System.Web.UI.TemplateParser.ProcessException(Exception ex)
at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding)
at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding)
at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding)
at System.Web.UI.TemplateParser.ParseReader(StreamReader reader, VirtualPath virtualPath)
at System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath)
at System.Web.UI.TemplateParser.ParseInternal()
at System.Web.UI.TemplateParser.Parse()
at System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType()
at System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider)
at System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders()
at System.Web.Compilation.BuildProvidersCompiler.PerformBuild()
at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath)
at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
at System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound)
at System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp)
at System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath)
at System.Web.UI.PageHandlerFactory.System.Web.IHttpHandlerFactory2.GetHandler(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath)
at System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig)
at System.Web.HttpApplication.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)