Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

Dropdown cascading not firing in updatepanel

$
0
0

Hi All,

I have three dropdown(ddl) controls with some asp.net validations controls, both these controls placed in one update panel.

With out selecting any think, I submited the page because of validation the page is not submited. (here comes the problem) . After submiting page dropdown cascading is not working.

Before submite the page (means before validation event) cascading is working fine.

Here is my code .

<asp:UpdatePanel ID="pnlPlaces" runat="server" class="fElement">
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="drpCountry" EventName="SelectedIndexChanged" />
        </Triggers>
            <ContentTemplate>
                <asp:DropDownList ID="drpCountry" runat="server" OnSelectedIndexChanged="drpCountry_SelectedIndexChanged"
                    AutoPostBack="true" Width="250" EnableViewState="true">
                </asp:DropDownList>
                <asp:UpdateProgress ID="updateProgress1" runat="server" AssociatedUpdatePanelID="pnlPlaces">
                    <ProgressTemplate>
                        <div style="" class="progBarW">
                            <asp:Image ID="cntUpdateProgress" runat="server" ImageUrl="~/images/loading_input.gif"
                                AlternateText="Loading ..." ToolTip="Loading ..." />
                        </div>
                    </ProgressTemplate>
                </asp:UpdateProgress>
                <asp:RequiredFieldValidator ID="valPriorityRequired" runat="server" ControlToValidate="drpCountry"
                    SetFocusOnError="true" Display="Dynamic" resourcekey="drpCountry.ErrorMessage"
                    ValidationGroup="Registration2" InitialValue="0" Text="*" class="fError">
                </asp:RequiredFieldValidator>
                <div id="divRegion" runat="server">
                    <label>
                        <% = Localization.GetString("Region", this.LocalResourceFile)%><span>:</span></label>
                    <asp:DropDownList ID="drpRegion"  EnableViewState="true" runat="server" AppendDataBoundItems="true" Width="250">
                        <asp:ListItem Text="" Value="" ></asp:ListItem>
                    </asp:DropDownList>
                </div>
                <div id="divDepartment" runat="server">
                    <label>
                        <% = Localization.GetString("Department", this.LocalResourceFile)%><span>:</span></label>
                    <asp:DropDownList ID="drpDepartment" runat="server" OnSelectedIndexChanged="drpDepartment_SelectedIndexChanged"
                        Width="200" AutoPostBack="true">
                    </asp:DropDownList>
                </div>
                <div id="divProvince" runat="server">
                    <label>
                        <% = Localization.GetString("Province", this.LocalResourceFile)%>
                        <span>:</span></label>
                    <asp:DropDownList ID="drpProvince" runat="server" OnSelectedIndexChanged="drpProvince_SelectedIndexChanged"
                        Width="200" AutoPostBack="true">
                    </asp:DropDownList>
                </div>
                <div id="divDistrict" runat="server">
                    <label>
                        <% = Localization.GetString("District", this.LocalResourceFile)%><span>:</span></label>
                    <asp:DropDownList ID="drpDistrict" runat="server" Width="200">
                    </asp:DropDownList>
                </div>
            </ContentTemplate>
        </asp:UpdatePanel>

Thanks.


Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>