.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Problems with Repeater Control, Update Panel and the Toolkit controls

Posted By:      Posted Date: October 25, 2010    Points: 0   Category :ASP.Net

Hi Guys,


Having a bit of an issue with the Toolkit controls.

I have a Repeater Control nested inside the Update panel, the repeater item template contains a multiview control allowing users to flick through seperate bits of information. This was working fine the async update was perfect, no issues.

I have then decided to include the rating control to one of the views. problem is now everytime i want to change the view it causes the whole page to postback.  

Attached is the code.

Any help is much appreciated

View Complete Post

More Related Resource Links

Treeview problems in Update panel



I tried using this code, on a Treeview inside an update panel, which is populated dynamically in code behind. 

However, it doesnt give me the required functionality.

Following is my aspx code for the TreeView and the TreeView populating logic:


<div id="treelist">
<asp:UpdatePanel ID="UpdatePanel1&quo

Accordion Control with Panel...Add an Update Panel?


I have an accordion control in my web site.  And in one of the panels, I have a drop down list box where, when the user selects an item, it updates the labels right below the ddlistbox.  I have it so that it maintains the scroll position when the ddlistbox has an autopostback, but it's very obvious that the whole page posts back.

My question is, can I/should I just enclose the ddlistbox and the labels (and a couple of text boxes) in an AJAX update panel?  I already have a ToolScriptManager (because of the accordion control), so I don't need to have another script manager, right?  I can just put the update panel (with the other controls inside of it) right in the accordion panel, right?  Then when the ddlistbox posts back it won't have the delay of the whole page posting back?  And it'll still execute the event handler for the listbox selection change?

Does this sound right?  I'm just looking to make the post back "invisible", and I would like to do a partial postback of just these few controls.

Thanks in advance! :)

changing records frm control in update panel


i have a list box, a command button and a grid

when i click a particular record / or multiple records on the  list box and then cclick the command button the records r transferred 2 the grid

i also have custom paging, the paging shld ocur as many times i clcik the command button

i have used updatepanel with the command button in it so that partial postback ocurs or there is no page flicker ,

but when i use update panel i get teh records in the grid but custom page is not working . it has no affect even if the records are added

if i remove update panel the paging works properly

how do i manage it with update panel

Using Update Panel on a repeater using Dropdown Autopostback

 Hi, The subject is explanatory, but here are some details:   I want to update a repeater when SelectedIndex value changes for a dropdown list. The problem is Nothing happens. My aspx page is present in a nested master page. and neither autopostback works nor update panel. i have set the AsyncPostBack trigger on SelectedIndexChange event.   Please let me know what am i doing wrong or what am i missing. PS: I have never worked on ajax before so I might have overlooked something.

AJAX update panel and update progress controls

I have writtena Crystal reports web application, that prompts ths user for parameters and then apply them and exports the report to a folder as .rpt and then display the report. I prompt the parameters on one screen and then display the report on another page. I have the AJAX update panel and update progress controls in the parameter page. When the user enters the parameters and click on ok, I export the report and then loads the report to a session report document and transfer the user to the second page where the report is displayed. I use the following code to do transfer to the seconds page. I have excluded the report load and parameter assign code here.rpt.ExportToDisk(ExportFormatType.CrystalReport, "c:\reports\testrep.rpt") Session("rpt") = New ReportDocument Session("rpt").load("c:\reports\testrep.rpt") Response.Redirect("show.aspx") In the second page I have the following: rptViewer.reportsource = Session("rpt") My problem is this works one time and then stops working the second. What I found out was it comes to the statement: Response.Redirect("show.aspx") But it does not even load the show.aspx page. It stays on the parameter page. There are no errors displayed. I could not see any errors when I debug the application also. And out of the blue it works

Modal Popup controls & Update panel

Dear frnds, I have a Modal Popup controls on the page. This will display some data.     It takes around 10 min to fetch the data to display on the popup control.     Code for displaying the popup control is on page behind.   So problem is that it takes 10 min to come up the popup. No indication till them on the page . All the controls are inside the update panel   Regards, Sajid P K  

Update panel with WebChart Control not happening :(

Hi guys,I have a drop down list with questions, according to selected question a chart is generated, when you enter the page and select a question for the first time, the chart gets generated correctly, but then when you select another question update panel doesn't show the updated chart (all charts are working, if i test the questions manually).Here is the update panel that i have:<asp:UpdatePanel ID="UpdatePanel1" runat="server" RenderMode="Inline">             <ContentTemplate>                   <Web:ChartControl ID="ChartControl1" runat="server" BorderStyle="Outset"                         BorderWidth="5px">                    </Web:ChartControl>                </ContentTemplate>             <Triggers>               

File upload control and update panel ... ab-normal behavior?

 I have two update panels on single page . 1st one contain drop down and some other controls. I have used asyncpostbacktrigger in 1st update panel.  while in second PostBackTrigger (because of file upload). When page loads , it first dislays the content of 1st udate panel, when I click button to show the content of 2nd update panel , its contents are not displayed. look at this code, it demonstrates what I mean to say. <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional"> <ContentTemplate> <asp:panel ID="pnl" runat="server"> <asp:DropDownList ID="drpdwn" runat="server"> <asp:ListItem>Item 1</asp:ListItem> <asp:ListItem>Item 2</asp:ListItem> </asp:DropDownList> </asp:panel> <asp:Button ID="lnkbtnNext" runat="server" Visible="false" onclick="Button1_Click" Text="Next" /> </ContentTemplate> <Triggers> <asp:AsyncPostBackTrigger ControlID="lnkbtnNext" /> </Triggers> </asp:UpdatePanel> <asp:UpdatePanel ID="updpnl3" runat="server" UpdateMode="Conditional"> <ContentTemplate> <asp:PlaceHolder ID=&qu

File Upload Control is not working in Update Panel

hi friend... i am using update panel... in one of my aspx page (ASP.NET 2.0)there is a file upload control in update panel which is used to upload company logo on server..when i remove the update panel.. than file upload is working properly..but when i again place an update panel then file upload control is not working and its giving me error.. in likeIf String.IsNullOrEmpty(fldLogo.PostedFile.FileName.ToString) Then                 as object reference not set to an instance of an object... can any body help me ?any idea ??  

How to determine if a user control is contained by the update panel that triggered async postback

Does anyone know a simple way to determine if a user control is contained in an update panel that was triggered for async postback?At the moment, the only pseudo logic for this I can think of is?'Loop through the update panel controls on the page and find the one that is involved in the postback (isInPartialRendering)'Try to find the user control as a child of the update panel

update panel problems

I am using AJAX update panel for handling post back, on post back i am only enabling and disabling controls, but some times the following error occurs on post back.Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.  Details: Error parsing near '    <!DOCTYPE html P'.Following is the code for refrence.Any Help would be Highly appreciated.Thanks in Advance//////////////////////////aspx code////////////////////////////////////////////<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="addriskpolicy.aspx.cs" Inherits="addriskpolicy" Title="Untitled Page" EnableEventValidation="false"%> <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server"> <script type="text/javascript" src="js/jsUpdateProgress.js"></script> <script type="text/javascript" language="javascript"> var ModalProgress = '<%= ModalProgress.ClientID %>'; </script> <asp:UpdatePanel id="upnl_accounts&

User Control with JQuery doesnot work inside update panel


Hi All,

I created a .NET user control to work as a DropdownCheckbox and added Jquery to give the sliding and hide effects. The code is as below:

 <script language="javascript" type="text/javascript">
        var showRegionWindow = function (ev) {
            var pos = $("#lnkChangeRegion").offset();
            var width = 230;
            var height = 55;
            //$("#changeRegionPanel").css({ "left": +((pos.left) - 215) + "px", "top": height + 16 + "px" });.
            document.getElementById("lnkChangeRegion").style.display = 'none';

        var hideRegionWindow = function (ev) {
            var textVal = "";

Dynamic Control in update panel



I am developing a page where i am generating dynamic control in Update panel. I am getting eror when I am assigning trigger's control ID.


  private void LoadControls(string strGridId, DateTime dtGridDate, bool bAllocReadonly)
            pnlSectorGrid.Visible = true;
            DataSet ds = GetSectorialGridData(strGridId, dtGridDate);
            Table table = new Table();
            table.ID = "Table1";

            for (int Index = 0; Index < ds.Tables[0].Rows.Count - 1; Index++)
                TableRow row = new TableRow();
                TableCell cell1 = new TableCell();
                TableCell cell2 = new TableCell();

                Label lblSectorName = new Label();
                lblSectorName.Text = ds.Tables[0].Rows[Index]["tsu_SubSectorName"].ToString();
                lblSectorName.Font.Size = 10;

                TextBox txtAlloc = new TextBox();
                txtAlloc.Text = ds.Tables[0].Rows[Index]["Alloc"].ToString();
                txtAlloc.Font.Size = 8;
                txtAlloc.Width = 90;
                txtAlloc.ReadOnly = bAllocReadonly;

Problem with User Control, Update panel and flicker


I have  block of code that consists of a textbox a button and a dropdown. The text entered in the text box filters the dropdownlist when the user clicks the button. The Ajax works great when it is in a simple page but if I put the same code in a User control I get flicker. Can anyone assist with this issue?

Trouble with update panel and dynamic controls and post back


 I have a page that is mostly dynamically built in the page load of my VB.net code behind page.

The issue is that I made a change to the page and added a button that redirects to a secondary page. When the button is clicked there is a very noticeable lag until the button click event fires because the page is being rebuilt every time.

I had not wrapped the code in the load event in the If not ispostback.... because I have dynamic controls that the user interacts with and I need the page to be rebuilt when the user clicks them.

The dynamic controls are clickable table cells. I did some looking and I found that the RegisterPostBackControl. I thought this would be perfect but, it does not although I maybe using it incorrectly.

Here is the code flow.

Page Load

If not ispostback then


end if


private sub setuppage()

'get a reference to the scriptmanager on the master page

Dim scriptManager = DirectCast

page inside update panel doesn't refresh the session object after postback of any control



I have many controls like dropdown, radiobuttonlist, etc on my page and I put all these controls inside the update panel so that the page doesn't look to be posting back when something is selected. Now the working on the page is very smooth. But the session object isn't getting refreshed even if I postback to the server and as a result even if the users are working on the page they are being sent to the login screen after 20 mins.

Is there anyway where I could put all the controls in update panel and still refresh the session after any postback(dropdown selection)

Any help is greatly appreciated.

Thanks in advance

Repeater Control Does not exist in current context, but other controls do


I have an aspx page containing a number of asp:Repeater Controls.

Im not using the default code-behind file that is generated, ive changed this to file in a different folder.

In the code-behind, i populate the repeater controls, all was workign fine until i added another repeater control to the aspx page.
In the code-behind, the intellisense picks up this control and i can access its methods and properties to set the datasource and bind the data. However, when i go to build the project, i get an error "The name Repeater1 does not exist in the current context"

Firstly, all the other repeater controls, declared in exactly the same way, do not throw throw this error.
Secondly, yes the repeater does have a runat="server" tag.
Thirdly, It is not inside any other controls.

I have tried various different methods of accessing this repater instead of just "Repeater1." but each returns null:

Repeater r1 = (Repeater)Page.FindControl("Repeater1") ;
Repeater r1 = (Repeater)Page.Master.FindControl("Repeater1"); 
Repeater r1 = (Repeater)Master.FindControl("Repeater1") ;

Ive no idea why this "doesnt exist in the current context" as all the other controls on this page do, even if i create a literal i get the same problem

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend