title: Passing common data into the _Layout.cshtml in ASP.Net MVC
body: <p>In an ASP.Net MVC Application, I'm trying to generate a top navigation bar from the database table. I follow the Database first approach. using EntityFramework</p>
  
  <p>My scenario as follows : </p>
  
  <p>I have 3 tables <code>MainMenu</code>, <code>SubMenu</code> and <code>ItemMenu</code>. The <code>ItemMenu</code> table knows it's MainMenu and the SubMenu. According to those details, the top menu bar should be rendered on the _Layout.cshtml page.</p>
  
  <p>How to implement this..? Should I create a partial view for MenuBar or is there any other easy ways to accomplish this?</p>