| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 802 人关注过本帖
标题:还是那个GDI的问题
只看楼主 加入收藏
chen3bing
Rank: 3Rank: 3
等 级:论坛游侠
帖 子:507
专家分:104
注 册:2008-11-12
结帖率:91.22%
收藏
 问题点数:0 回复次数:0 
还是那个GDI的问题
我把GDI的头文件拷贝到VC98里的include文件夹下,吧库文件拷贝到VC98下面的lib文件夹下。
重现建立了一个单文本框程序
Stdafx.h文件如下:
#if !defined(AFX_STDAFX_H__7DBD9734_B583_4123_81D1_BF02805EBA03__INCLUDED_)
#define AFX_STDAFX_H__7DBD9734_B583_4123_81D1_BF02805EBA03__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
//#include <Windows.h>
#pragma comment(lib, "gdiplus.lib")
#define ULONG_PTR ULONG




#define VC_EXTRALEAN        // Exclude rarely-used stuff from Windows headers
#include <afxdtctl.h>
#include "Gdiplus.h"
using namesapace Gdiplus;
#pragma comment(lib, "gdiplus.lib")
#include <afxwin.h>         // MFC core and standard components
#include <afxext.h>         // MFC extensions
#include <afxdisp.h>        // MFC Automation classes
//#include <afxdtctl.h>        // MFC support for Internet Explorer 4 Common Controls
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h>            // MFC support for Windows Common Controls
#endif // _AFX_NO_AFXCMN_SUPPORT

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_STDAFX_H__7DBD9734_B583_4123_81D1_BF02805EBA03__INCLUDED_)
其中using namesapace Gdiplus;这句编译出错:
d:\vc\study\1\dd\xx\stdafx.h(22) : error C2146: syntax error : missing ';' before identifier 'Gdiplus'
d:\vc\study\1\dd\xx\stdafx.h(22) : error C2873: 'namesapace' : symbol cannot be used in a using-declaration
d:\vc\study\1\dd\xx\stdafx.h(22) : fatal error C1004: unexpected end of file found
执行 cl.exe 时出错.

xx.exe - 1 error(s), 0 warning(s)
请高手指教,谢谢!
搜索更多相关主题的帖子: Stdafx include GDI MFC lib 
2022-12-14 19:08
快速回复:还是那个GDI的问题
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.014530 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved