I work on an windows phone 7.1 app on Visual Studio 2010. I try to do that:
dynamic dyn = JsonConvert.DeserializeObject(json);
MessageBox.Show(dyn.somevar);
I have this error:
One or more types required to compile a dynamic expression cannot be found. Are you missing references to Microsoft.CSharp.dll and System.Core.dll?
I tried to add C:\Program Files (x86)\Microsoft SDKs\Silverlight\v4.0\Libraries\Client\Microsof.CSharp.dll
but it doesn't work.
What can I do now?
Dynamic
keyword requires .Net Framework 4.0. (and DLR).
Windows Phone 7 (and 8) has it's own version of .Net Framework. And dynamic language runtime is not included.
So, you can't use it for Windows Phone development.
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