简体   繁体   English

无法将AjaxToolkit控件添加到用户控件

[英]Can't add AjaxToolkit Control to User Control

I have a simple user control and I want to add an AjaxToolkit control to it. 我有一个简单的用户控件,我想向其中添加一个AjaxToolkit控件。 The one I want is the ModalPopupExtender, but the same thing happens no matter which AjaxToolkit control I choose. 我想要的是ModalPopupExtender,但是无论我选择哪种AjaxToolkit控件,都会发生相同的情况。 When I drag and drop the control onto the Source page instead of appending the @Register line and the tags I get a whole bunch of xml type code starting with 当我将控件拖放到“源”页面上而不是附加@Register行和标签时,我得到了一堆以xml开头的xml类型代码

<soap-env:envelope soap-env:encodingstyle="........

I have even tried manualy typing in an @Register line adding ToolkitScriptManager line and then a ModalPopupExtender and no joy. 我什至尝试手动输入添加工具包脚本行的@Register行,然后再输入ModalPopupExtender,这并不令人高兴。

Any help appreciated. 任何帮助表示赞赏。

Praveen Correct only happened in UserControl (ascx file)... I tried fixing first by doing a clean. Praveen正确仅发生在UserControl(ascx文件)中...我先尝试通过清洁进行修复。 This did not help. 这没有帮助。 I then closed VS2010 and cleared the ReflectedSchemas directory and this fixed the issue. 然后,我关闭了VS2010,并清除了ReflectedSchemas目录,从而解决了该问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM