2
Answers

RenderPartial Dynamically from Database Values

Photo of Sairam

Sairam

9y
748
1
Hi 
 
I am having index.cshml where i render multiple partial like
Html.RenderPartial("emp1"); 
Html.RenderPartial("emp2");  
 
Now i want to make this renderpartial dynamic.I want to fetch values from DB .
emp1,emp2 are data available in the database.I want to fetch this data from db and using loop i want to make html.renderpartial
 
Can somebody provide an idea to make it using knockout and mvc .

Answers (2)