title: How create Dropdown list only using ViewBag in ASP.NET MVC 4?
body: <p>Here I have a model class..</p>
  
  <pre><code>public class MyDrop
  {
      public int id { get; set; }
      public string value { get; set; }
  }
  </code></pre>
  
  <p>In my controller I use this code....</p>
  
  <pre><code>public ActionResult Index(){
  
      var GenreLst = new List&lt;MyDrop&gt;();
  
      MyDrop a = new MyDrop();
      a.id = 1;
      a.value = "hello";
  
      MyDrop b = new MyDrop();
      b.id = 2;
      b.value = "hello2";
  
      GenreLst.Add(a);
      GenreLst.Add(b);
      ViewBag.ShowDropDown = new SelectList(GenreLst); 
  
  
  }
  </code></pre>
  
  <p>Then in my view I add this code...</p>
  
  <pre><code>@Html.DropDownList("ShowDropDown", "All")
  </code></pre>
  
  <p>After run the project.It show a dropdown list.
  But not showing correct values.</p>
  
  <p>In the page source it likes this.... </p>
  
  <pre><code>&lt;select id="ShowDropDown " name="ShowDropDown "&gt;&lt;option value=""&gt;All&lt;/option&gt;
  &lt;option&gt;DropDown.Models.MyDrop&lt;/option&gt;
  &lt;option&gt;DropDown.Models.MyDrop&lt;/option&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>How do I solve this???</p>
  
  <p>I was Expected like this.....</p>
  
  <pre><code>&lt;select id="ShowDropDown " name="ShowDropDown "&gt;&lt;option value="0"&gt;All&lt;/option&gt;
  &lt;option value="1"&gt;hello&lt;/option&gt;
  &lt;option value="2"&gt;hello2&lt;/option&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>Please Help......</p>