Click here to Skip to main content
15,900,816 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

I am trying to create RuleModel class dynamically.

var myType = MyTypeBuilder.CompileResultType();
ViewBag.Rule = RuleModel.Create(myType);

During runtime it rases an exception for the following line:
" Html.CodeEffects().Scripts().Render();"

Exception message:
Could not find or load assembly "MyDynamicType, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null". Error message: Could not load file or assembly 'MyDynamicType, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified. (Error S103)

Can you please quide me how to create RuleModel class dynamically.

Thanks & Regards,
Swathi N
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900