UpdatePanel not behaving as expected

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • DeekoVB5@gmail.com

    UpdatePanel not behaving as expected

    I can't get an UpdatePanel on my page to work. One control - an
    ImageButton in a GridView - works the first time you click on it, but
    then freezes all of the controls on the form. The paging controls of
    the GridView refresh the entire page, as if the UpdatePanel wasn't
    there. There is an outside control - a dropdownlist - which is set to
    trigger the updatepanel, and also refreshes the entire page. Below
    are some snippets from the code. Any ideas?


    <asp:ScriptMana gerProxy ID="ScriptManag erProxy1" runat="server" />
    ....
    <asp:DropDownLi st ID="ChildSites " runat="server" AutoPostBack="T rue"
    OnSelectedIndex Changed="ChildS ites_SelectedIn dexChanged"></
    asp:DropDownLis t>
    ....
    <asp:UpdatePane l ID="MainUpdateP anel" runat="server"
    updatemode="Con ditional" childrenastrigg ers="true">
    <Triggers>
    <asp:AsyncPostB ackTrigger ControlID="Chil dSites" />
    </Triggers>
    <ContentTemplat e>
    <div >
    <divTotal<img src="star_activ e.png" alt="Approved" />s: <asp:Label
    ID="TotalStarsL abel" runat="server" /></div>
    </div>
    <asp:GridView ID="Announcemen tsGrid" runat="server"
    enablepaging="t rue" PageSize="10"
    OnRowDataBound= "AnnouncementsG rid_ItemDataBou nd">
    <Columns>
    <asp:TemplateFi eld>
    <ItemTemplate >
    <asp:ImageButto n ID="ApprovalSta tusImage" runat="server"
    ImageUrl="star_ inactive.png" OnClick="Approv alStatus_Clicke d" />
    </ItemTemplate>
    </asp:TemplateFie ld>
    </Columns>
    </asp:GridView>
    </ContentTemplate >
    </asp:UpdatePanel >
  • bruce barker

    #2
    Re: UpdatePanel not behaving as expected

    you have a ScriptManagerPr oxy, but did you define a ScriptManger on the
    page (or master)?

    -- bruce (sqlwork.com)

    DeekoVB5@gmail. com wrote:
    I can't get an UpdatePanel on my page to work. One control - an
    ImageButton in a GridView - works the first time you click on it, but
    then freezes all of the controls on the form. The paging controls of
    the GridView refresh the entire page, as if the UpdatePanel wasn't
    there. There is an outside control - a dropdownlist - which is set to
    trigger the updatepanel, and also refreshes the entire page. Below
    are some snippets from the code. Any ideas?
    >
    >
    <asp:ScriptMana gerProxy ID="ScriptManag erProxy1" runat="server" />
    ...
    <asp:DropDownLi st ID="ChildSites " runat="server" AutoPostBack="T rue"
    OnSelectedIndex Changed="ChildS ites_SelectedIn dexChanged"></
    asp:DropDownLis t>
    ...
    <asp:UpdatePane l ID="MainUpdateP anel" runat="server"
    updatemode="Con ditional" childrenastrigg ers="true">
    <Triggers>
    <asp:AsyncPostB ackTrigger ControlID="Chil dSites" />
    </Triggers>
    <ContentTemplat e>
    <div >
    <divTotal<img src="star_activ e.png" alt="Approved" />s: <asp:Label
    ID="TotalStarsL abel" runat="server" /></div>
    </div>
    <asp:GridView ID="Announcemen tsGrid" runat="server"
    enablepaging="t rue" PageSize="10"
    OnRowDataBound= "AnnouncementsG rid_ItemDataBou nd">
    <Columns>
    <asp:TemplateFi eld>
    <ItemTemplate >
    <asp:ImageButto n ID="ApprovalSta tusImage" runat="server"
    ImageUrl="star_ inactive.png" OnClick="Approv alStatus_Clicke d" />
    </ItemTemplate>
    </asp:TemplateFie ld>
    </Columns>
    </asp:GridView>
    </ContentTemplate >
    </asp:UpdatePanel >

    Comment

    • DeekoVB5@gmail.com

      #3
      Re: UpdatePanel not behaving as expected

      Yes, the ScriptManager is defined on the Master page. I've tried
      leaving off the ScriptManagerPr oxy and just using the Master page's
      ScriptManager, same problem.

      Comment

      Working...