---
title: "Create Dropdown in MVC with static value"  
description: "Create Dropdown in MVC with static value"  
author: "Anonymous User"  
published: 2017-12-14  
updated: 2017-12-14  
canonical: https://www.mindstick.com/forum/34398/create-dropdown-in-mvc-with-static-value  
category: "c#"  
tags: ["asp.net mvc", "mvc", "mvc4", "razor"]  
reading_time: 2 minutes  

---

# Create Dropdown in MVC with static value

Hi [Expert](https://www.mindstick.com/articles/13120/an-expert-financial-advice-will-improve-your-finances),

I want to change way of create [dropdown menu](https://www.mindstick.com/forum/158697/how-can-implement-a-dropdown-menu-or-navigation-bar-with-hover-effects-using-jquery) in my [razor view](https://www.mindstick.com/forum/155820/how-to-generate-textbox-control-using-htmlhelper-in-razor-view).

Here is my [code](https://yourviews.mindstick.com/view/85458/alan-turing-the-mastermind-behind-cracking-the-enigma-code-during-world-war-ii):

```
<div class="col-md-6">
                                @{
        List<SelectListItem> listItems = new List<SelectListItem>();
        listItems.Add(new SelectListItem { Text = "Approved", Value = "A" });
        listItems.Add(new SelectListItem { Text = "Pending", Value = "P", Selected = true });
        listItems.Add(new SelectListItem { Text = "Rejected", Value = "R" });
                                }
                                <label for="status">Status</label>
                                @Html.DropDownListFor(model => model.Status, listItems, "-- Select Status --", new { @class = "form-control" })
                            </div>
```

Please give me some solution to achieve this task.

## Replies

### Reply by Hemant Patel

Hi Aarav,

I analyzed your code. You can also create static [dropdown](https://www.mindstick.com/articles/263/ajax-toolkit-dropdownextender-in-asp-dot-net) in your [razor](https://www.mindstick.com/articles/12002/asp-dot-net-mvc5-razor-with-jquery) view with different manner.

Please follow below line of code.

```
<label for="status">Status</label>
                                @Html.DropDownListFor(model => model.Status, new List<SelectListItem> { new SelectListItem { Text = "Approved", Value = "A"}, new SelectListItem { Text = "Pending",

Value = "P", Selected = true  }, new SelectListItem { Text = "Rejected", Value = "R" } }, "-- Select Status --", new { @class = "form-control" })
```

Hope its helpful!!!!


---

Original Source: https://www.mindstick.com/forum/34398/create-dropdown-in-mvc-with-static-value

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
