I created a dynamic object like below:
dynamic myObject = new
{
DisplayName = "Mahesh"
};
Content = Parse("Main", myObject);
Then I parsed it for Razor template. But it doesnt work because of the object cannot access to its properties. What is the problem here ?
Thanks in advance,
I did it by this way and it works. But I want to know why the way I did first is not working
dynamic FooterModel = new ExpandoObject();
FooterModel.DisplayName= "Kaplan";
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With