qtmaind.lib(qtmain_win.obj) : error LNK2019: 无法解析的外部符号 __imp_CommandLineToArgvW,该符号在函数 WinMain 中被引用

报错:qtmaind.lib(qtmain_win.obj) : error LNK2019: 无法解析的外部符号 __imp_CommandLineToArgvW,该符号在函数 WinMain 中被引用

原因: 未包含Shell32.lib

解决1:

#pragma comment(lib, "Shell32.lib")

解决2:

属性管理器:链接器->输入->附加依赖项->Shell32.lib (在常规中添加好对应附加库目录)

参考:https://blog.csdn.net/Ada_who/article/details/80159064

原文地址:https://www.cnblogs.com/2018shawn/p/11320998.html

时间: 2024-08-06 07:05:24

qtmaind.lib(qtmain_win.obj) : error LNK2019: 无法解析的外部符号 __imp_CommandLineToArgvW,该符号在函数 WinMain 中被引用的相关文章

使用SDL2出现 “error LNK2019: 无法解析的外部符号 _SDL_main,该符号在函数 _main 中被引用” 时的可能错误记录

这几天在使用SDL2,之前一直都没有错,直到上午把项目搬了个地方.结果一直出现 “error LNK2019: 无法解析的外部符号 _SDL_main,该符号在函数 _main 中被引用” . 看了网上的方法都说是没有正确定义 main 函数 ,这是SDL2main.lib指定需要的函数.结果我把他定义在了"xx.h"这样的头文件中. 原来我一直没理解头文件和源文件的重要区别.把 main 函数定义在 "xx.cpp" 这样的源文件中就可以正确编译了. 看来还需要再

VS2015+OpenGL4.0开发编译时弹出错误:glaux.lib(tk.obj) : error LNK2019: 无法解析的外部符号 _sscanf,该符号在函数 [email protected] 中被引用

一.问题描述: VS2015+OpenGL4.0开发编译时弹出如下所示的错误: 1>glaux.lib(tk.obj) : error LNK2019: 无法解析的外部符号 _sscanf,该符号在函数 [email protected] 中被引用 1>glaux.lib(tk.obj) : error LNK2019: 无法解析的外部符号 _vsprintf,该符号在函数 _PrintMessage 中被引用 二.问题原因: VS2015默认编译时将许多标准库采用内联方式处理,因而没有可以链

MSVCRTD.lib(crtexe.obj) : error LNK2019: 无法解析的外部符号 _main,该符号在函数 ___tmainCRTStart

vs2012 这个错误的解决方法: 项目/属性/连接器/系统/子系统 把控制台 (/SUBSYSTEM:CONSOLE)改为 窗口 (/SUBSYSTEM:WINDOWS) 顺便说一下我的主函数是 int WINAPI WinMain(HINSTANCE hInst,HINSTANCE,LPSTR cline,INT)

【转】strmbasd.lib(dllentry.obj) : error LNK2001: 无法解析的外部符号"int g_cTemplates"

加入了DirectShow的基类链接库后,如果此时编译就会出现以下编译错误: strmbasd.lib(wxutil.obj) : error LNK2019: 无法解析的外部符号 [email protected] strmbasd.lib(wxutil.obj) : error LNK2019: 无法解析的外部符号 [email protected] strmbasd.lib(dllentry.obj) : error LNK2001: 无法解析的外部符号 "class CFactoryTe

ACE_TEST1.obj : error LNK2019: 无法解析的外部符号

ACE_TEST1.obj : error LNK2019: 无法解析的外部符号 "int __cdecl ace_main_i(int,char * * const)" ([email protected]@[email protected]) ,该符号在函数 "private: virtual int __thiscall ACE_Main::run_i(int,char * * const)" ([email protected][email protecte

vs2015编译ffmpeg 出现错误rtmp.lib(rtmp.obj) : error LNK2001: 无法解析的外部符号 ___iob_func

vs2015编译ffmpeg(版本3.0.2)引用外部库文件librtmp出现以下错误: rtmp.lib(rtmp.obj) : error LNK2001: 无法解析的外部符号 __imp__strtod rtmp.lib(rtmp.obj) : error LNK2001: 无法解析的外部符号 __imp__sscanf rtmp.lib(rtmp.obj) : error LNK2001: 无法解析的外部符号 __imp___snprintf rtmp.lib(rtmp.obj) : e

error LNK2019: 无法解析的外部符号 [email protected],该符号在函数 ___tmainCR...(转)

一,问题描述 MSVCRTD.lib(crtexew.obj) : error LNK2019: 无法解析的外部符号 [email protected],该符号在函数 ___tmainCRTStartup 中被引用  Debug\jk.exe : fatal error LNK1120: 1 个无法解析的外部命令 error LNK2001: unresolved external symbol [email protected] debug/main.exe:fatal error LNK 1

error LNK2019: 无法解析的外部符号 [email protected],该符号在函数。。。使用

一,问题描述 MSVCRTD.lib(crtexew.obj) : error LNK2019: 无法解析的外部符号 [email protected],该符号在函数 ___tmainCRTStartup 中被引用 Debug\jk.exe : fatal error LNK1120: 1 个无法解析的外部命令 error LNK2001: unresolved external symbol [email protected] debug/main.exe:fatal error LNK 11

error LNK2019 无法解析的外部符号 __imp___invalid_parameter 解决方案

此报错是在用OpenGL画图时遇到的(OpenGL是项目名称): 1>------ 已启动生成: 项目: OpenGL, 配置: Debug Win32 ------ 1>glad.c 1>源.cpp 1>源.obj : error LNK2019: 无法解析的外部符号 __imp___invalid_parameter,该符号在函数 "void * __cdecl std::_Allocate_manually_vector_aligned<struct std: