Using page properties as dynamic properties

Sometimes in EPiServer you need properties that inherit values.Dynamic Properties is great for that, but as Anders Hattestad claims (and proposes a solution), it's a bit tricky working with these in EPiServer CMS 7+ versions.

In a current project, we needed just that; have a variety of inherited property values that could be overwritten and break the chain. The logic to find the property values is similar to (i.e. exact) to the solution Anders proposes, but I moved the binding to our ViewModel instead.

Oh, and perhaps you could inherit and return an object of type PropertyData instead of a generic type. And the code might be in need of some error handling. Use freely and with care.