gpt4 book ai didi

winforms - 在设计模式下显示带有自定义控件的 WinForm 时出错

转载 作者:行者123 更新时间:2023-12-04 17:41:27 28 4
gpt4 key购买 nike

我有一个 UserControl,它是类库的一部分。我从我的解决方案中引用了这个项目。这会将引用项目中的控件添加到我的工具箱中。我将 tghe 控件添加到表单中。一切看起来都不错,我编译并运行。完美的...

但是,当我关闭带有控件的 .frm 并重新打开它时,出现此错误。代码继续运行。

它可能与命名空间有关。最初的命名空间只是“设计”,这是模棱两可且相互矛盾的,所以我决定重命名它。我想那是我的问题开始的时候。

    To prevent possible data loss before loading the designer, the following errors must be resolved:   



2 Errors

Ignore and Continue
Why am I seeing this page?





Could not find type 'Besi.Winforms.HtmlEditor.Editor'. Please make sure that the assembly that contains this type is referenced. If this type is a part of your development project, make sure that the project has been successfully built using settings for your current platform or Any CPU.




Instances of this error (1)

1. There is no stack trace or error line information available for this error.


Help with this error

Could not find an associated help topic for this error. Check Windows Forms Design-Time error list


Forum posts about this error

Search the MSDN Forums for posts related to this error






The variable 'Editor1' is either undeclared or was never assigned. Go to code





Instances of this error (1)

1. BesiAdmin frmOrder.Designer.vb Line:775 Column:1 Show Call Stack

at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.Error(IDesignerSerializationManager manager, String exceptionText, String helpLink)
at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeExpression(IDesignerSerializationManager manager, String name, CodeExpression expression)
at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeExpression(IDesignerSerializationManager manager, String name, CodeExpression expression)
at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeStatement(IDesignerSerializationManager manager, CodeStatement statement)

Help with this error

MSDN Help


Forum posts about this error

Search the MSDN Forums for posts related to this error

最佳答案

要尝试的几件事:

  • 检查您的 frmOrder.Designer.vb文件错误,或者可能使用了错误的命名空间。我知道它可能会说不要在评论中触及文件,但有时你必须这样做。小心点。
  • 如果可以,请尝试清理/重建您的项目。
  • 删除并重新添加对 dll 的引用(并确保使用正确的命名空间引用正确的版本)。也许缓存了不应该缓存的东西。
  • 退出并重新启动VS。
  • 关于winforms - 在设计模式下显示带有自定义控件的 WinForm 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3020294/

    28 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com