Try our conversational search powered by Generative AI!

exception typecasting a block to a page.


Hello all,

I'm having trouble with a particular block that EPiServer seems to think is a page. Im experiencing an exception with the following exception message : Content with id '4963' is of type 'Castle.Proxies.UserListBlockProxy' which does not inherit required type 'EPiServer.Core.PageData'.

So what would cause EPiServer to try and cast my Block as a Page?

This only happens on postback. The page initially loads fine. Its only when the page is being built on postback that this error occurs.

Has anyone experienced anything similar? Does anyone have any ideas? Thanks in advance!

Nov 24, 2015 17:04


Maybe somewhere in your code you are using page templates definition, but you should use block template definitions. I mean instead of TemplatePage it should be BlockControlBase (in WebForms) or in MVC - PageController while BlockController should be used.

Nov 24, 2015 19:20
* 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.