Add/remove operation is impossible, because the code element is readonly
Posted on 2012-08-28 11:30 theEagles 阅读(251) 评论(0) 收藏 举报在VS2008中,有时候添加类的消息响应函数会弹出 “Add/remove operation is impossible, because the code element is readonly”
解决方案是:
如果在这个出问题的类的头文件里定义了任何函数,把函数代码从头文件剪切到cpp文件里。关闭Visual Studio,删除ncb文件和suo文件。
打开工程,待Intellisesnce update完毕后,添加消息响应代码。
浙公网安备 33010602011771号