我想在GridView里添加一列DropDownList并且表头做成这个样式的
哪位帮忙解决一下!~~
先谢过了.....

解决方案 »

  1.   

    模板列中添加DropDownList
    http://topic.csdn.net/u/20100510/11/4345a56f-4548-47e1-a1b3-857de8d236a8.html?55977
      

  2.   

    给个例子你 
     <form id="form1" runat="server">
        <div>
        
        </div>
       <asp:GridView ID="messagelist" runat="server" AutoGenerateColumns="False" 
                            Width="759px" DataSourceID="Sqlljm" AllowPaging="True" PageSize="5">
                            <PagerSettings FirstPageText="" LastPageText="" NextPageText="" 
                                PreviousPageText="" />
                            <Columns>
                                <asp:TemplateField>
                                   <ItemTemplate>
                                        <table cellspacing="0" cellpadding="0" width="700" align="center" border="0" valign="top">
                                            <tr>
                                                <td  colspan="2" height="25">
                                                   
                                                    <asp:DropDownList ID="DropDownList1" runat="server">
                                                    </asp:DropDownList>
                                                </td>
                                            </tr>
                                            <tr>
                                                <td style="height: 31px" colspan="2">
                                                   
                                                </td>
                                            </tr>

    </TABLE>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                    </Columns>
                                </asp:GridView>
       
        </form>