这是我的代码
<dx:GridViewDataTextColumn Width="10%" FieldName="TestAlert" CellStyle-HorizontalAlign="Center">
<DataItemTemplate>
<dx:ASPxDropDownEdit ClientInstanceName="checkComboBox" ID="ASPxDropDownEdit1" runat="server" AnimationType="None" >
<DropDownWindowStyle BackColor="#EDEDED" />
<DropDownWindowTemplate>
<dx:ASPxListBox Width="100%" ID="listBox" ClientInstanceName="checkListBox" SelectionMode="CheckColumn"
runat="server">
<Border BorderStyle="None" />
<BorderBottom BorderStyle="Solid" BorderWidth="1px" BorderColor="#DCDCDC" />
<Items>
<dx:ListEditItem Text="(Select all)" />
<dx:ListEditItem Text="Alert" Value="1" />
<dx:ListEditItem Text="Delete" Value="2" />
</Items>
<ClientSideEvents SelectedIndexChanged="OnListBoxSelectionChanged" />
</dx:ASPxListBox>
<table style="width: 100%">
<tr>
<td style="padding: 4px">
<dx:ASPxButton ID="ASPxButton1" AutoPostBack="False" runat="server" Text="Close" style="float: right">
<ClientSideEvents Click="function(s, e){ checkComboBox.HideDropDown(); }" />
</dx:ASPxButton>
</td>
</tr>
</table>
</DropDownWindowTemplate>
<%-- <ClientSideEvents TextChanged="SynchronizeListBoxValues" DropDown="SynchronizeListBoxValues" />--%>
</dx:ASPxDropDownEdit>
任何人都可以帮我选择ex:ALert的值,同时点击按钮......
ListBox listBox = (ListBox)LawyerASPxGridView.FindRowCellTemplateControl(e.VisibleIndex, LawyerASPxGridView.DataColumns["ListBox"], "listBox");
listBox.Items.FindByText("Alert").Selected = true;
但是这会抛空......请帮帮我