That's exactly what I was looking for. Thank you Jorge.
On 10 Feb., 22:28, Jorge Barnaby Rubio <
jorge.barn...@gmail.com>
wrote:
> I do it this way:
>
> public class BaseSiteController : ARSmartDispatcherController
> {
> public override void Initialize()
> {
> base.Initialize();
>
> PropertyBag["siteCharset"] = "value";
> }
>
> }
>
> Hope it helps!
>
> yorch.
>
> On Feb 10, 5:28 am, Lee Henson <
lee.m.hen...160@gmail.com> wrote:
>
> > One choice is to use a filter.
>
> > [Filter(ExecuteWhen.BeforeAction,
> > typeof(IPreloadBaseControllerPropertyBagFilter)]
> > public class BaseController {
>
> > }
>
> > public class PreloadBaseControllerPropertyBagFilter : IFilter {
> > public virtual bool Perform(.....) {
> > controllerContext.PropertyBag.Add("mykey", myvalue);
> > }
>
> > }
>
> > 2009/2/10 Ben Lovell <
benjamin.lov...162@gmail.com>
>
> > > Could you override the propertybag and do your stuff there? I've not got VS
> > > open in front of me so that's a question as much as an answer ;)
>