2012-01-13 25 views
0

asp.net 需要使用CSS樣式此下拉列表...如何風格ASP下拉內部的按鈕

<style type="text/css"> 
    .cascadingDropDownList{ background-color:Red;} 
    .cascadingDropDownList button{ background-color:Green; } 
</style> 

<asp:DropDownList ID="ddlVehicleMake" runat="server" CssClass="cascadingDropDownList" /> 

的背景色爲紅色文本框的一部分,但不是綠色的按鈕。我怎樣才能訪問按鈕的CSS屬性?

+0

請提供您的HTML,而不是您的.NET源代碼。 – 2012-01-13 18:54:58

+1

它並不那麼容易。 http://forums.asp.net/t/1087992.aspx/1?How+to+style+the+dropdownlist+s+button+你可以試試jQuery:http://filamentgroup.com/lab/jquery_ui_selectmenu_an_aria_accessible_plugin_for_styling_a_html_select/ – 2012-01-13 18:56:09

回答