是什么原因导致“无法注销UpdatePanel的'错误? [英] What causes the 'Cannot unregister UpdatePanel' error?

查看:132
本文介绍了是什么原因导致“无法注销UpdatePanel的'错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个包含一个UpdatePanel一个用户控件。当我把一个页面上,它引发以下错误:

I've got a UserControl that contains an UpdatePanel. When I put that on a page, it throws the following error:

无法与ID注销的UpdatePanel
  ReviewContentUpdatePanel',因为它
  未与登记的
  的ScriptManager。这可能会发生,如果
  的UpdatePanel从除去
  控制树,后来再次添加,
  不被支持。参数
  名称:的UpdatePanel

Cannot unregister UpdatePanel with ID 'ReviewContentUpdatePanel' since it was not registered with the ScriptManager. This might occur if the UpdatePanel was removed from the control tree and later added again, which is not supported. Parameter name: updatePanel

ReviewContentUpdatePanel 是更新面板和蓝光的名称;它没有被删除或code补充,它存在于aspx页面,并不会被删除。有没有人碰到这之前?

ReviewContentUpdatePanel is the name of the update panel & it's not being removed or added in code, it exists in the aspx page and isn't removed. Has anyone come across this before?

推荐答案

在控件集合在其中的UpdatePanel是居住使用的清除方法,或者当特定的UpdatePanel使用的删除方法

This error occurs when the Controls collection in which the UpdatePanel is resided is cleared using the Clear method, or when the specific UpdatePanel is removed using the Remove method.

一个这些方法的触发可能的<一个实施href=\"http://msdn.microsoft.com/en-us/library/system.web.ui.control.createchildcontrols.aspx\">CreateChildControls对于控制方法的包含在UpdatePanel。通常情况下,你叫Controls.Clear()在这个方法的顶部,开始用干净的石板,如果这种方法被反复调用。

A trigger for these methods could be the implementation of the CreateChildControls method for the control contains the UpdatePanel. Usually, you call Controls.Clear() in the top of this method, to start with a clean slate if this method is called repeatedly.

这篇关于是什么原因导致“无法注销UpdatePanel的'错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆