Webflypostbackmanager causing full postback

13 replies. Last post: September 10, 2009 4:53 AM by Xedem
Tags :
  • New Discussion
  • New Question
  • New Product Feedback
Xedem Member

 Hi

    About webflypostback: I have tried using the samples and tutorials and played around doing some modifications. However when i applied webflypostbackmanager in my project, it is not working as it should be. The following is the design code of wfpm, if it would help.

 <ISWebDesktop:WebFlyPostBackManager ID="wfpmBlocks" runat="server" EnableUIMode="true" UpdateMode="AllControls">
<FlyPostBackSettings PostControlState="True" PostHiddenFields="True" PostInputControls="True"
PostViewState="True">
</FlyPostBackSettings>

However except one control all controls are causing fullpostback. And moreover only a partialupdate is caused. I will explain. My scenario is as follows. I have got an outer asp.net panel, and inside that an html table is located. For this table i have got two rows.On the first row i ve got a datepicker. On the second row, i have got another table with 9 rows and 8 td each. The design as follows. Full design is out of scope, hence am omitting 7 repeating rows.

<table cellpadding="0" cellspacing="0" border="0" style="height: 100%; width: 100%;">
<tr>
<td style="height: 1px;" colspan="2">
<table id="Tab1" runat="server" class="patient" width="100%">
<tr>
<td class="calendar" style="white-space: nowrap; vertical-align: middle;"> The datepicker comes here
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td style="width: 99%; height: 100%;">
<table border="1" id="Master1" runat="server" cellspacing="0" cellpadding="0" class="scheduleContainer">
<tr id="mainRow" style="background-color: #D1DCEF;">
<th style="width: 3%; height: 1px;">
<asp:Label ID="lblWeek" Text="Week" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
<th style="width: 14%;">
<asp:Label ID="lblMonday" Text="Monday" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
<th style="width: 14%;">
<asp:Label ID="lblTuesday" Text="Tuesday" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
<th style="width: 14%;">
<asp:Label ID="lblWednesday" Text="Wednesday" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
<th style="width: 14%;">
<asp:Label ID="lblThursday" Text="Thursday" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
<th style="width: 14%;">
<asp:Label ID="lblFriday" Text="Friday" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
<th style="width: 14%;">
<asp:Label ID="lblSaturday" Text="Saturday" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
<th style="width: 14%;">
<asp:Label ID="lblSunday" Text="Sunday" runat="server" CssClass="scheduleHeader"></asp:Label>
</th>
</tr>
<tr>
<td style="height: 12.1%;">
<asp:Label ID="wk1" runat="server" CssClass="scheduleLeftColumn"></asp:Label>
</td>
<td>
<asp:Label ID="dtc1" runat="server" Width="100%" CssClass="scheduleDate" />
<asp:Panel CssClass="scheduleDataHolder" runat="server" ID="d1">
</asp:Panel>
</td>
<td>
<asp:Label ID="dtc2" runat="server" Width="100%" CssClass="scheduleDate" />
<asp:Panel CssClass="scheduleDataHolder" runat="server" ID="d2">
</asp:Panel>
</td>
<td>
<asp:Label ID="dtc3" runat="server" Text="i" Width="100%" CssClass="scheduleDate" />
<asp:Panel CssClass="scheduleDataHolder" runat="server" ID="d3">
</asp:Panel>
</td>
<td>
<asp:Label ID="dtc4" runat="server" Text="i" Width="100%" CssClass="scheduleDate" />
<asp:Panel CssClass="scheduleDataHolder" runat="server" ID="d4">
</asp:Panel>
</td>
<td>
<asp:Label ID="dtc5" runat="server" Text="i" Width="100%" CssClass="scheduleDate" />
<asp:Panel CssClass="scheduleDataHolder" runat="server" ID="d5">
</asp:Panel>
</td>
<td>
<asp:Label ID="dtc6" runat="server" Text="i" Width="100%" CssClass="scheduleDate" />
<asp:Panel CssClass="scheduleDataHolder" runat="server" ID="d6">
</asp:Panel>
</td>
<td>
<asp:Label ID="dtc7" runat="server" Text="i" Width="100%" CssClass="scheduleDate" />
<asp:Panel CssClass="scheduleDataHolder" runat="server" ID="d7">
</asp:Panel>
</td>
</tr>
………………………………………………………………..Other rows will come here……………………………………………………..
</table>
</td>
<td style="width: 1px; height: 100%;">
<table class="samllBoxes2" style="width: 3%; clear: right; height: 100%; background-color: Transparent;
clear: left">
<tr>
<td style="height: 22px;">
</td>
</tr>
<tr>
<td style="clear: left; width: 5%; padding-top: 0px; vertical-align: top; height: 1px;">
<asp:ImageButton ImageUrl="~/assets/schDown_32.png" ID="Img1" runat="server" />
</td>
</tr>
<tr>
<td style="height: 100%; padding-top: 0;">
</td>
</tr>
<tr>
<td style="clear: left; width: 5%; padding-top: 0; vertical-align: top; height: 1px;">
<asp:ImageButton ID="Img2" ImageUrl="~/assets/schUp_32.png" runat="server" />
</td>
</tr>
</table>
</td>
<asp:HiddenField ID="hdnUtility" runat="server" />
<asp:HiddenField ID="hdnStartDate" runat="server" />
</tr>
</table>

The above is the small part of my design, which is relevant to the question.When datepicker is clicked all labels are updated without any problem, asynchronously(for eg:those with id starting with dtc). Am adding some labels dynamically to the panels with class=schedueldataholder. When asynchronous post is made these labels are never get updated or removed. However i can do it work by making clientaction.markasdirty(panelID). This is done just after updating the panels in my code. But tell me if there is any performance penalty in doing this, as each panel is put as dirty once it is iterated. Now am applying background color to td. however i cant remove the color or change it because markasdirty option is not applicable to td or to table container. So i changed the markasdirty option to be applicable to entire panel holding all these controls. Am getting error like an alert box showing error message. Now for img1 and img2 full postback is only working. Why? Am not using custom update mode. However i tried with custom update mode and added these two controls and datepicker to the list. Now all controls are causing full postback. I even used updateviewstate for the first problem. The following is the server code.

listener = New WebFlyPostBackListener(Me)
wfpmBlocks.ServiceUrl = "ScheduleCalendar.aspx" & Request.Url.Query

Hope someone can help on this.

 

 

 
Vinayan
All times are GMT -5. The time now is 4:37 PM.
Previous Next