How can I create a standalone .aspx page outside of Telligent framework

We're running 6.1 version of the platform.  I want to create a standalone .aspx page on our site, which is completely separate from the Telligent "hooks".  If I try to create such a page, I get the following error unless I derive my page class from Telligent.Evolution.Components.CSPage (instead of just System.Web.UI.Page). 

Is this possible?  Thank you,

Dan

 

System.Web.HttpCompileException (0x80004005): [physical path to my code behind]:

error ASPNET: Make sure that the class defined in this code file matches the 'inherits' attribute,

and that it extends the correct base class (e.g. Page or UserControl).   

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.HttpApplication.MaterializeHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

  • I found my own answer, for anyone interested.

    In my .aspx page, specifically in the Page directive at the top, add the attribute:

    CodeFileBaseClass="System.Web.UI.Page"

    And, from the code-behind, derive your class from System.Web.UI.Page.

    The reason for this behavior in the first place, I found, is because the web.config file for the site contains an attribute in the <system.web><pages> node named "pageBaseType" set to "Telligent.Evolution.Components.CSPage", which force that to be the base class for any page in the site.  The steps above allowed me to override that default setting for my one-off page.

    Hope this helps anyone else who's up against a similar need.

    Thanks,

    Dan August

Related