I am trying to get the Ajax loading panel to work with a service that when they pick a person it does some active directory look-ups and save them to a database. But I cannot get the control working with a textbox that has a service in it.
My text box has an autocomplete service in it that when they pick a name does a looup to AD then saves to DB. Sometimes it takes quite a while for this to happen and I want to show a loading panel but it will not work with the service in there. It blocks out my service.
My text box has an autocomplete service in it that when they pick a name does a looup to AD then saves to DB. Sometimes it takes quite a while for this to happen and I want to show a loading panel but it will not work with the service in there. It blocks out my service.
<form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager> <telerik:RadAjaxManager ID="radmanager" runat="server"> <AjaxSettings> <telerik:AjaxSetting AjaxControlID="txtName"> <UpdatedControls> <telerik:AjaxUpdatedControl ControlID="txtName" LoadingPanelID="radLoad" /> </UpdatedControls> </telerik:AjaxSetting> </AjaxSettings> </telerik:RadAjaxManager> <div class="deletepg" > <h4>Delete Exisitng Active Directory Account</h4> <br /> Find User: <asp:TextBox ID="txtName" runat="server" Width="260px" AutoPostBack="true"></asp:TextBox> <asp:AutoCompleteExtender ID="txtName_ACE" runat="server" DelimiterCharacters="" Enabled="True" ServicePath="~/iMACService.asmx" ServiceMethod="FindName" TargetControlID="txtName" UseContextkey="true" MinimumPrefixLength="3" OnClientItemSelected="Selected" EnableCaching="true" CompletionInterval="1" /> <asp:TextBoxWatermarkExtender ID="txtName_WME" runat="server" TargetControlID="txtName" WatermarkText="Enter Last Name First Name" WatermarkCssClass="WaterMark" /> </div> <asp:HiddenField ID="HFPersId" runat="server" /><asp:HiddenField ID="HFUserId" runat="server" /> <telerik:RadAjaxLoadingPanel ID="radLoad" runat="server" BackgroundPosition="Center" Direction="RightToLeft" MinDisplayTime="3000"></telerik:RadAjaxLoadingPanel> </form>Protected Sub txtName_TextChanged(sender As Object, e As EventArgs) Handles txtName.TextChanged If HFPersId.Value = String.Empty Then ScriptManager.RegisterClientScriptBlock(Page, GetType(Page), "OpenWindow", "alert('You must pick a user to delete.');", True) ClearPage() Else VerifyInfo() End If End SubPrivate Sub VerifyInfo() Dim VReturn As String = String.Empty Dim mac As String = String.Empty mac = CreateMacNum() sql = "execute usp_DeleteUser " & Convert.ToInt32(HFPersId.Value) & ", " & Convert.ToInt32(HFUserId.Value) & ", '" & mac & "'" VReturn = getData(sql).Rows(0)(0).ToString If VReturn = "0" Then ScriptManager.RegisterClientScriptBlock(Page, GetType(Page), "OpenWindow", "alert('User has already been deleted from Active Directory and all local data tables have been updated.');", True) ElseIf VReturn = "1" Then ScriptManager.RegisterClientScriptBlock(Page, GetType(Page), "OpenWindow", "alert('A current MAC has been submitted for user. This MAC must be closed before submitting another.');", True) ElseIf VReturn = "2" Then ScriptManager.RegisterClientScriptBlock(Page, GetType(Page), "OpenWindow", "alert('User has been submitted for Deletion from Active Directory.');", True) Else ScriptManager.RegisterClientScriptBlock(Page, GetType(Page), "OpenWindow", "alert('Something happened with the deletion process. Please put in a HDT with error.');", True) End If ClearPage() End Sub