Hi,
I found a problem on the radcombobox on my radgrid. If I selected couple of values from the combobox by using autocomplete separator & click update, it didn't work at all. If I selected only one value from the combobox, it could be updated properly on the table on my sql database.
Can any of you tell me what is wrong ?
<%@ Page Language="VB" %>
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">
</script>
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
</telerik:RadScriptManager>
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="RadGrid1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RadGrid1" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RadCombobox1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RadGrid1" LoadingPanelID="RadAjaxLoadingPanel1" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server"
Transparency="50">
<div style="background-color: #FFFFFF; height: 100%;">
<asp:Image ID="Image1" runat="server" ImageUrl="loading1.gif"
AlternateText="loading" ImageAlign="AbsMiddle" />
</div>
</telerik:RadAjaxLoadingPanel>
<br />
<br />
<telerik:RadComboBox ID="RadComboBox1" Runat="server"
DataSourceID="SqlDataSource3" DataTextField="F5" DataValueField="F5"
Height="20px" MaxHeight="500px" Width="412px" AutoPostBack="True"
Skin="WebBlue" AppendDataBoundItems="True">
<Items>
<telerik:RadComboBoxItem value="0", Text="Please select your name..." />
</Items>
</telerik:RadComboBox>
<asp:SqlDataSource ID="SqlDataSource3" runat="server"
ConnectionString="<%$ ConnectionStrings:usagelogConnectionString %>"
SelectCommand="SELECT DISTINCT F5 FROM OriginalReport"></asp:SqlDataSource>
<br />
<br />
<telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="False" DataSourceID="SqlDataSource1"
GridLines="None" Skin="WebBlue" AllowAutomaticDeletes="True" AllowAutomaticInserts="True" AllowAutomaticUpdates="True" >
<HeaderContextMenu CssClass="GridContextMenu GridContextMenu_WebBlue"></HeaderContextMenu>
<MasterTableView DataKeyNames="F1"
DataSourceID="SqlDataSource1" CommandItemDisplay="TopAndBottom">
<RowIndicatorColumn FilterControlAltText="Filter RowIndicator column"></RowIndicatorColumn>
<ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column"></ExpandCollapseColumn>
<Columns>
<telerik:GridEditCommandColumn ButtonType="ImageButton" HeaderText="Edit" >
<HeaderStyle Width="10px" />
</telerik:GridEditCommandColumn>
<telerik:GridBoundColumn DataField="F1" DataType="System.Int32" HeaderText="ID#"
ReadOnly="True" SortExpression="F1" UniqueName="F1"
FilterControlAltText="Filter F1 column">
</telerik:GridBoundColumn>
<telerik:GridDateTimeColumn DataField="F2"
FilterControlAltText="Filter F2 column" HeaderText="Publication Date"
UniqueName="F2">
</telerik:GridDateTimeColumn>
<telerik:GridBoundColumn DataField="F3" HeaderText="DocID" SortExpression="F3"
UniqueName="F3" FilterControlAltText="Filter F3 column">
</telerik:GridBoundColumn>
<telerik:GridHTMLEditorColumn DataField="F4"
FilterControlAltText="Filter F4 column" HeaderText="Report Title"
UniqueName="F4">
</telerik:GridHTMLEditorColumn>
<telerik:GridBoundColumn DataField="F5" FilterControlAltText="Filter F5 column"
HeaderText="Written by..." SortExpression="F5" UniqueName="F5">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="F6" FilterControlAltText="Filter F6 column"
HeaderText="Written by..." SortExpression="F6" UniqueName="F6">
</telerik:GridBoundColumn>
<telerik:GridDropDownColumn DataField="F7" DataSourceID="SqlDataSource5"
FilterControlAltText="Filter F7 column" HeaderText="Content Type"
ListTextField="F1" ListValueField="F1" UniqueName="F7">
</telerik:GridDropDownColumn>
<telerik:GridDropDownColumn DataField="F8" DataSourceID="SqlDataSource4"
FilterControlAltText="Filter F8 column" HeaderText="Industry"
ListTextField="F1" ListValueField="F1" UniqueName="F8">
</telerik:GridDropDownColumn>
<telerik:GridTemplateColumn DataField="F9"
FilterControlAltText="Filter F9 column" HeaderText="Global Vendor"
UniqueName="F9">
<EditItemTemplate>
<telerik:RadComboBox ID="F9RadComboBox" runat="server" AllowCustomText="True"
AutoCompleteSeparator=";" DataSourceID="SqlDataSource2" DataTextField="F1"
DataValueField="F1" Height="19px" MarkFirstMatch="True"
SelectedValue='<%# Bind("F9") %>' Width="504px" MaxHeight="500px" >
</telerik:RadComboBox>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="F9Label" runat="server" Text='<%# Eval("F9") %>'></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridBoundColumn DataField="F10" FilterControlAltText="Filter F10 column"
HeaderText="Vendor manual input" SortExpression="F10" UniqueName="F10">
</telerik:GridBoundColumn>
</Columns>
<EditFormSettings>
<EditColumn UniqueName="EditCommandColumn1" >
</EditColumn>
</EditFormSettings>
<CommandItemSettings ShowExportToCsvButton="True" ShowExportToExcelButton="True"
ShowExportToPdfButton="True" ShowExportToWordButton="True" />
</MasterTableView>
<FilterMenu EnableImageSprites="False"></FilterMenu>
</telerik:RadGrid>
<br />
<br />
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:usagelogConnectionString %>"
DeleteCommand="DELETE FROM [OriginalReport] WHERE [F1] = @F1"
InsertCommand="INSERT INTO [OriginalReport] ([F2], [F3], [F4], [F5], [F6], [F7], [F8], [F9], [F10]) VALUES (@F2, @F3, @F4, @F5, @F6, @F7, @F8, @F9, @F10)"
SelectCommand="SELECT [F1], [F2], [F3], [F4], [F5], [F6], [F7], [F8], [F9], [F10] FROM [OriginalReport] WHERE ([F5] = @F5)"
UpdateCommand="UPDATE [OriginalReport] SET [F2] = @F2, [F3] = @F3, [F4] = @F4, [F5] = @F5, [F6] = @F6, [F7] = @F7, [F8] = @F8, [F9] = @F9, [F10] = @F10 WHERE [F1] = @F1">
<SelectParameters>
<asp:ControlParameter ControlID="RadComboBox1" Name="F5"
PropertyName="SelectedValue" Type="String" />
</SelectParameters>
<DeleteParameters>
<asp:Parameter Name="F1" Type="Int32" />
</DeleteParameters>
<UpdateParameters>
<asp:Parameter Name="F2" Type="DateTime" />
<asp:Parameter Name="F3" Type="String" />
<asp:Parameter Name="F4" Type="String" />
<asp:Parameter Name="F5" Type="String" />
<asp:Parameter Name="F6" Type="String" />
<asp:Parameter Name="F7" Type="String" />
<asp:Parameter Name="F8" Type="String" />
<asp:Parameter Name="F9" Type="String" />
<asp:Parameter Name="F10" Type="String" />
<asp:Parameter Name="F1" Type="Int32" />
</UpdateParameters>
<InsertParameters>
<asp:Parameter Name="F2" Type="DateTime" />
<asp:Parameter Name="F3" Type="String" />
<asp:Parameter Name="F4" Type="String" />
<asp:Parameter Name="F5" Type="String" />
<asp:Parameter Name="F6" Type="String" />
<asp:Parameter Name="F7" Type="String" />
<asp:Parameter Name="F8" Type="String" />
<asp:Parameter Name="F9" Type="String" />
<asp:Parameter Name="F10" Type="String" />
</InsertParameters>
</asp:SqlDataSource>
</div>
<asp:SqlDataSource ID="SqlDataSource2" runat="server"
ConnectionString="<%$ ConnectionStrings:usagelogConnectionString %>"
SelectCommand="SELECT * FROM [Vendors] ORDER BY [F1]"></asp:SqlDataSource>
<asp:SqlDataSource ID="SqlDataSource4" runat="server"
ConnectionString="<%$ ConnectionStrings:usagelogConnectionString %>"
SelectCommand="SELECT * FROM [Industry] ORDER BY [F1]"></asp:SqlDataSource>
<asp:SqlDataSource ID="SqlDataSource5" runat="server"
ConnectionString="<%$ ConnectionStrings:usagelogConnectionString %>"
SelectCommand="SELECT * FROM [contenttype] ORDER BY [F1]">
</asp:SqlDataSource>
</form>
</body>
</html>