视觉工作室错误LNK1104和设计器无法显示此文件,因为其中的任何类都无法设计

时间:2017-04-28 19:12:18

标签: c++ opencv visual-studio-2015

我知道这是一个重复的问题,但我找不到任何解决方案。

我创建了新的CLR空项目并且出现this错误,所以我搜索了解决方案,除了我关闭myform.h并从解决方案资源管理器再次打开它并且工作正常然后我没有为我工作从NuGet包管理器安装opencv,当我添加包含

#include "opencv2\core\core.hpp"
#include "opencv\cv.h"
#include "opencv\highgui.h"
#include "opencv2\opencv.hpp"

出现错误

Error   LNK1104 cannot open file 'C:\Users\OneDrive\Documents\Visual Studio 2015\Projects\algorithms\projectimage\x64\Debug\projectimage.exe'

然后我也搜索了解决方案,他们都没有解决它,所以我尝试关闭整个项目并再次打开它,两个错误一起出现,我试图关闭myform.h并再次打开它但它不会消失所以任何请帮助解决这两个错误

enter image description here

我的主要

#include "MyForm.h"
using namespace System;
#include "opencv2\core\core.hpp"
#include "opencv\cv.h"
#include "opencv\highgui.h"
#include "opencv2\opencv.hpp"
using namespace System::Windows::Forms;

[STAThread]
void main() {
    Application::EnableVisualStyles();
    Application::SetCompatibleTextRenderingDefault(false);
    projectimage::MyForm form;
    Application::Run(%form);

}

注意:我使用的是visual studio 2015和opencv版本2.4.11 c ++

0 个答案:

没有答案