Solved

Drop Down with bootstrap can't format it... New help.

Posted on 2014-10-23
3
158 Views
Last Modified: 2014-10-29
I have the following code and I'm not sure how to apply the bootstrap on the drop down.

Full code:
<div class="form-inline">
            Find by Last Name or First Name: @Html.TextBox("SearchString", ViewBag.CurrentFilter as String, new { style = "width:200px", @class = "form-control" })

            Location:

            @Html.DropDownList("LocationList", "All")

            <input type="submit" value="Search" class="btn btn-default" />
        </div>

Open in new window


Drop Down. Not sure what I have to modify here.

   @Html.DropDownList("LocationList", "All")

Open in new window

0
Comment
Question by:yguyon28
  • 2
3 Comments
 
LVL 58

Accepted Solution

by:
Gary earned 500 total points
ID: 40400602
Apply Bootstrap to do what?

@Html.DropDownList("LocationList", "All", new { @class="some-class-name" })

Open in new window

0
 

Author Comment

by:yguyon28
ID: 40401912
Garry I followed your advice but I get this error.
@Html.DropDownList("LocationList", "All", new { @class="some-class-name" })

I get this error
0
 

Author Comment

by:yguyon28
ID: 40401977
CS1928: 'System.Web.Mvc.HtmlHelper<PagedList.IPagedList<TweddlePhoneListApplication.Models.MasterList>>' does not contain a definition for 'DropDownList' and the best extension method overload 'System.Web.Mvc.Html.SelectExtensions.DropDownList(System.Web.Mvc.HtmlHelper, string, System.Collections.Generic.IEnumerable<System.Web.Mvc.SelectListItem>, object)' has some invalid arguments
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
looking for an ASP.net report designer 4 40
Groupbox Control ? 2 27
linq .concat equivalent with expression syntax 4 22
WPF user control poped up from a window 1 35
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

680 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question