Friday, 15 April 2011

asp.net - Problems with the UpdatePanel -



asp.net - Problems with the UpdatePanel -

when drag , drop updatepanel on user command variable in auto generated file of user control:

/// <summary> /// updatepanel1 control. /// </summary> /// <remarks> /// auto-generated field. /// modify move field declaration designer file code-behind file. /// </remarks> protected global::system.web.ui.webcontrols.updatepanel updatepanel1;

however, updatepanel found in different namespace:

/// <summary> /// updatepanel1 control. /// </summary> /// <remarks> /// auto-generated field. /// modify move field declaration designer file code-behind file. /// </remarks> protected global::system.web.ui.updatepanel updatepanel1;

i have config entry in web.config under assemblies config section:

<add assembly="system.web.extensions, version=3.5.0.0, culture=neutral, publickeytoken=31bf3856ad364e35"/>

why behavior happening me?

1) either reset system.web.ui.webcontrols.webparts.updatepanel system.web.ui.updatepanel (same scriptmanager) every time ascx file modified.. recommended, tedious.

2) found using register command @ top of ascx file seemed override default behavior of designer pick 4.0 location 3.5 command (i think underlying issue, 4.0 designer backwards compatible 3.5). recommended, careful while adding controls asp:

<%@ register tagprefix="asp" namespace="system.web.ui" assembly="system.web"%> ... <asp:scriptmanager runat="server" id="smlocationsmap" />

3) can include system.web.dll, , system.web.design.dll in bin folder (security/other issues). not recommended.

blog link

asp.net updatepanel

No comments:

Post a Comment