asp.net mvc 2 - How pass model and View Date to PartialView? -


how pass model , view date partialview?

my code show error:

 <%html.renderpartial("~/views/location/location.ascx", new mvclocation.models.locationmodel(), (ienumerable<selectlistitem>)viewdata["unit"]); %> 

you don't need explicitly pass viewdata items partial views parameter. yo can access viewdata item in partial view.


Comments

Popular posts from this blog

c++ - Is it possible to compile a VST on linux? -

java - Output of Eclipse is rubbish -

jquery - Confused with JSON data and normal data in Django ajax request -