-
-
Notifications
You must be signed in to change notification settings - Fork 52
Description
Hi theres. I have encounted problem that I really can't understand.
CS code is very simple :
await RazorTemplateEngine.RenderAsync(viewName, viewModel);
that code above throw exception say : "The model item passed into the ViewDataDictionary is of type 'Miscellaneous.MiscellaneousInvoiceViewModel', but this ViewDataDictionary instance requires a model item of type 'Miscellaneous.MiscellaneousInvoiceViewModel'."
However the problem does not occur immediately when the application starts. which will happen sometime later (1 month, 2 months after). Means when the application has been running for a while. And until when i restart the app, everything is normal again.
I also find out case the same problem in there. But i am not have RazorTemplateEngine.Initialize()
in my code.
I would be very grateful if you could help