Please help...losing my mind trying to get this to work.
Simple scenario...
Radcombo on rcb.aspx page with a button that opens rad window (works)
radwindow has a form to enter new value to db (works)...upon closing the windows the radcombo should refresh, it's not even though record is successgully added to db. I have looked through various examples and it should work but it's not
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="SqlDataSource1" />
<telerik:AjaxUpdatedControl ControlID="RadComboBox1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RadComboBox1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RadComboBox1" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
<telerik:RadComboBox ID="RadComboBox1" runat="server" EnableViewState="false" AutoPostBack="true"
DataSourceID="SqlDataSource1" DataTextField="CompanyName" DataValueField="CompanyID">
</telerik:RadComboBox>
<asp:Button ID="Button1" runat="server" Text="Button" CausesValidation="False" />
<telerik:RadWindowManager ID="RadWindowManager1" runat="server">
<Windows>
<telerik:RadWindow ID="RadWindow1" runat="server" Behavior="Default" InitialBehavior="None"
Left="" NavigateUrl="clientwindow.aspx" OpenerElementID="Button1" Style="display: none;"
Top="" OnClientClose="ClientClose">
</telerik:RadWindow>
</Windows>
</telerik:RadWindowManager>
<telerik:RadCodeBlock runat="server">
<script type="text/javascript">
function openWindow() {
var oWnd = radopen("ClientWindow.aspx", "RadWindow1");
oWnd.setSize(495, 340);
var combo = $find("<%=RadComboBox1.ClientID %>");
//combo.setvalue("");
}
// function selectedIndexChanging(sender, args) {
// if (args.get_item().get_value() == "-1")
// args.set_cancel(true);
// }
function ClientClose(arguments) {
var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
ajaxManager.ajaxRequestWithTarget('<%= RadAjaxManager1.UniqueID %>', '');
}
</script>
</telerik:RadCodeBlock>
vb code:
the codes executes but it seems the radcombo is not ajaxified
Protected Sub RadAjaxManager1_AjaxRequest(ByVal sender As Object, ByVal e As Telerik.Web.UI.AjaxRequestEventArgs)
'Bind the RadComboBod
RadComboBox1.DataSource = Nothing
RadComboBox1.DataBind()
SqlDataSource1.DataBind()
RadComboBox1.DataSourceID = "SqlDataSource1"
RadComboBox1.DataBind()
' RadComboBox1.
End Sub
Simple scenario...
Radcombo on rcb.aspx page with a button that opens rad window (works)
radwindow has a form to enter new value to db (works)...upon closing the windows the radcombo should refresh, it's not even though record is successgully added to db. I have looked through various examples and it should work but it's not
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="SqlDataSource1" />
<telerik:AjaxUpdatedControl ControlID="RadComboBox1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RadComboBox1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RadComboBox1" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
<telerik:RadComboBox ID="RadComboBox1" runat="server" EnableViewState="false" AutoPostBack="true"
DataSourceID="SqlDataSource1" DataTextField="CompanyName" DataValueField="CompanyID">
</telerik:RadComboBox>
<asp:Button ID="Button1" runat="server" Text="Button" CausesValidation="False" />
<telerik:RadWindowManager ID="RadWindowManager1" runat="server">
<Windows>
<telerik:RadWindow ID="RadWindow1" runat="server" Behavior="Default" InitialBehavior="None"
Left="" NavigateUrl="clientwindow.aspx" OpenerElementID="Button1" Style="display: none;"
Top="" OnClientClose="ClientClose">
</telerik:RadWindow>
</Windows>
</telerik:RadWindowManager>
<telerik:RadCodeBlock runat="server">
<script type="text/javascript">
function openWindow() {
var oWnd = radopen("ClientWindow.aspx", "RadWindow1");
oWnd.setSize(495, 340);
var combo = $find("<%=RadComboBox1.ClientID %>");
//combo.setvalue("");
}
// function selectedIndexChanging(sender, args) {
// if (args.get_item().get_value() == "-1")
// args.set_cancel(true);
// }
function ClientClose(arguments) {
var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
ajaxManager.ajaxRequestWithTarget('<%= RadAjaxManager1.UniqueID %>', '');
}
</script>
</telerik:RadCodeBlock>
vb code:
the codes executes but it seems the radcombo is not ajaxified
Protected Sub RadAjaxManager1_AjaxRequest(ByVal sender As Object, ByVal e As Telerik.Web.UI.AjaxRequestEventArgs)
'Bind the RadComboBod
RadComboBox1.DataSource = Nothing
RadComboBox1.DataBind()
SqlDataSource1.DataBind()
RadComboBox1.DataSourceID = "SqlDataSource1"
RadComboBox1.DataBind()
' RadComboBox1.
End Sub