"CheckBox"是"System.Web.UI.WebControls.CheckBox"和"System.Windows.Forms.CheckBox"之间的歧义引用 [英] 'CheckBox' is an ambiguous reference between 'System.Web.UI.WebControls.CheckBox' and 'System.Windows.Forms.CheckBox'
问题描述
我正在使用来自名称空间System.Windows.Forms
的类ToolTip
编辑我的Web应用程序;我的代码中有几个复选框,因此它显示此错误:
I am editing my web application with the class ToolTip
which is coming from the namespace System.Windows.Forms
; There are a few checkboxes in my code and because of this it is displaying this error:
"CheckBox"是之间的含糊不清的引用
System.Web.UI.WebControls.CheckBox
和System.Windows.Forms.CheckBox1
'CheckBox' is an ambiguous reference between
System.Web.UI.WebControls.CheckBox
andSystem.Windows.Forms.CheckBox1
我该怎么做才能在Web应用程序中运行此工具提示
What should I do to run this tooltip in my web application
推荐答案
问题是,您在using
部分中引用了System.Web.UI.WebControls
和System.Windows.Forms
.如果您同时需要两者,则可以使用System.Web.UI.WebControls
中的明确复选框,方法是:
The problem is, that u have referenced System.Web.UI.WebControls
and System.Windows.Forms
in the using
-section. If you need both you can use checkbox explicit from System.Web.UI.WebControls
by saying:
using CheckBox = System.Web.UI.WebControls.CheckBox
这篇关于"CheckBox"是"System.Web.UI.WebControls.CheckBox"和"System.Windows.Forms.CheckBox"之间的歧义引用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!