开发者

Partial views in asp.net mvc

开发者 https://www.devze.com 2023-03-25 14:59 出处:网络
We are having reusable partial views with separate model associated with it. while doing post back, the开发者_Go百科 partial view model is not getting populated and its returning null.

We are having reusable partial views with separate model associated with it. while doing post back, the开发者_Go百科 partial view model is not getting populated and its returning null.

Example

ViewPage<ParentModel>

<%Htmlhelper.RenderPartial<controlname,ParentModel.ChildModel>

Please advice what am i doing wrong ?

Thanks Subu


Looks like you are not passing data to the partial view, so it has nothing to render as it does not know what to parse into view.

0

精彩评论

暂无评论...
验证码 换一张
取 消