Virtual Happy Hour this month, Jun 28, we'll be getting a sneak preview at our soon to launch SaaS CMS!

Try our conversational search powered by Generative AI!

Access to built-in Properties of BlockData?


Hi folks,

I'm trying to access to built-in properties of BlockData such as CreatedBy, Created however Its seem no easy way to achieve it, casting to BlockData, IContent, IContentData did not help, I can see them when debugging but they are belong to Proxy type at runtime. Does any one know how to achieve it? 

Any help would be very appriciated!

Feb 25, 2013 4:08

Doing reflection can solve the problem but I dont want to use reflection.

Feb 25, 2013 5:54


You'll have to cast to the interface which defines the properties, ie IChangeTrackable, IVersionable etc. Note that you may want to begin by checking if the block is IContent in case the block is a "local" block which won't implement those interfaces.

Given that the block is a shared block you can have a look at what interfaces the ContentMixin class and its base class BasicContent implements. All of those interfaces will be implemented by your shared block as well.

Feb 25, 2013 8:42

Thank you Joel!

It sounds make sense, I'll give it a try. 


ps: I'm enjoy reading your blog. 


Feb 25, 2013 10:25
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* 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.