GetSystemTime(建议使用GetLocalTime) 或者直接用标准C中的tm结构及其相关函数。Client: Included in Windows XP, Windows 2000 Professional, Windows NT Workstation, Windows Me, Windows 98, and Windows 95. Server: Included in Windows Server 2003, Windows 2000 Server, and Windows NT Server. Header: Declared in Winbase.h; include Windows.h. Library: Use Kernel32.lib.
去掉windows.h,然后在所有的.h文件前加入#include "stdafx.h"菜单Project Setting->C/C++ 选择Code Generation ,在Use Run-Time Library 下拉框中选择Debug Multithread菜单Project->Setting->General中 选择Using MFC in a Shared DLL或Using MFC in a static Library
我添加了AFX.H,说这个错误c:\program files\microsoft visual studio\vc98\mfc\include\afxv_w32.h(14) : fatal error C1189: #error : WINDOWS.H already included. MFC apps must not #include <windows.h>
试试小三的方法 你建的是WIN 32的工程吗?
UP -----------------------------打造国内最大免费编程资源站招聘C/C++版主 硬件嵌入式开发版主。有兴趣的来瞧瞧,网址:www.dvpx.com
或者直接用标准C中的tm结构及其相关函数。Client: Included in Windows XP, Windows 2000 Professional, Windows NT Workstation, Windows Me, Windows 98, and Windows 95.
Server: Included in Windows Server 2003, Windows 2000 Server, and Windows NT Server.
Header: Declared in Winbase.h; include Windows.h.
Library: Use Kernel32.lib.
选择Code Generation ,在Use Run-Time Library 下拉框中选择Debug Multithread菜单Project->Setting->General中
选择Using MFC in a Shared DLL或Using MFC in a static Library
你建的是WIN 32的工程吗?
-----------------------------打造国内最大免费编程资源站招聘C/C++版主 硬件嵌入式开发版主。有兴趣的来瞧瞧,网址:www.dvpx.com