title: DropDownList in MVC 4 with Razor
body: <p>I'm trying to create a <code>DropDownList</code> on a razor view.</p>
  
  <p>Would someone help me with this?</p>
  
  <p><strong>Normal HTML5 code:</strong></p>
  
  <pre><code>&lt;select id="dropdowntipo"&gt;
      &lt;option value="Exemplo1"&gt;Exemplo1&lt;/option&gt;
      &lt;option value="Exemplo2"&gt;Exemplo2&lt;/option&gt;
      &lt;option value="Exemplo3"&gt;Exemplo3&lt;/option&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>I tried this:</p>
  
  <pre><code>@{
      var listItems = new List&lt;ListItem&gt; { 
          new ListItem { Text = "Exemplo1", Value = "Exemplo1" }, 
          new ListItem { Text = "Exemplo2", Value = "Exemplo2" }, 
          new ListItem { Text = "Exemplo3", Value = "Exemplo3" } 
      };
  }
  
  @Html.DropDownListFor(model =&gt; 
      model.tipo, 
      new SelectList(listItems), 
      "-- Select Status --"
  )
  </code></pre>