Try our conversational search powered by Generative AI!

Unable to cast object of type 'ASP._404_aspx' to type 'EPiServer.PageBase'



I have been trying to create a content mangeable 404 error page. Mostly successful and appears to work locally. On deploying to the server I get a the error Unable to cast object of type 'ASP._404_aspx' to type 'EPiServer.PageBase'.

I have created a custom 404.aspx page at the root of the site, following an article found here: It's a fairly old article but appears to apply exatly to our setup. Any thing extra I need to do to avoid this error?

CMS 5 as in the article.



Dec 20, 2010 17:58

Hi Henrik,

you need to inherit from SimplePage or TemplatePage. Will probably solve the issue. :)

Dec 20, 2010 18:15
Hi Erik, Thanks very much - had to be something simple; works perfectly now.
Dec 21, 2010 10:09
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.