none
vs2022查看类图,报错“无法将一个或多个选定的项添加到类图中。这可能是由于该工具的若干限制所致,请单击帮助了解详细信息。” RRS feed

  • 问题

  • 在安装了最新的 Visual studio 2022专业版后,在将以前项目的C++代码拖放到类图 设计器中时,或者通过查看类图菜单时,

    提示出错对话框,“无法将一个或多个选定的项添加到类图中。这可能是由于该工具的若干限制所致,请单击帮助了解详细信息。”

    这些代码以前在Visual studio 2019社区版中,拖放类图都好的,不知时什么原因。

    2023年1月16日 9:24

全部回复

  • 检查您的代码是否有错误。
    确保所选代码元素在类设计器中受支持。 (例如,仅支持本机 C++ 代码。)
    确保引用了所有必需的程序集。

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    2023年1月18日 3:15
  • 您好,必需的程序集都是什么?
    2023年2月11日 3:15
  • 指程序运行所需要的dll文件。程序是否编译正常?
    请对类文件进行略微更改然后保存。相关文档: 类设计器错误 - Visual Studio (Windows) |微软学习 (microsoft.com)
    To resolve the error, drag the modified or relocated source code to the class diagram again to display it.

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    2023年3月14日 7:32