1、stdafx.cpp
// stdafx.cpp : 只包括标准包含文件的源文件 // ProCApp.pch 将作为预编译头 // stdafx.obj 将包含预编译类型信息 #include "stdafx.h" CString g_sExePath; // Exe执行路径 CString g_sSysFlag; // 系统标志位 CString g_sSysVersion; // 系统版本 CString g_sDBFlag; // 数据库类型0 Access 1 SQLServer 2 Oracle CString g_sDBServerIP; // SQLServer数据库服务器 CString g_sDataBase; // SQLServer数据库名称 CString g_sUserName; // SQLServer用户帐号 CString g_sPassword; // SQLServer用户密码 CString g_sAccessFile; // 数据库类型为Access的数据库文件 CString g_sOraDataSource; // Oracle数据库服务名称 CString g_sOraUser; // Oracle用户帐号 CString g_sOraPWD; // Oracle用户密码 CString g_sFtpIP; // Ftp服务器 CString g_sFtpPort; // Ftp端口 CString g_sFtpUser; // Ftp用户帐号 CString g_sFtpPWD; // Ftp用户密码
2、stdafx.h
// stdafx.h : 标准系统包含文件的包含文件,
// 或是经常使用但不常更改的
// 特定于项目的包含文件
// add by jzh 2009-07-05
#pragma once
#ifndef _SECURE_ATL
#define _SECURE_ATL 1
#endif
#ifndef VC_EXTRALEAN
#define VC_EXTRALEAN // 从 Windows 头中排除极少使用的资料
#endif
// 如果您必须使用下列所指定的平台之前的平台,则修改下面的定义。
// 有关不同平台的相应值的最新信息,请参考 MSDN。
#ifndef WINVER // 允许使用特定于 Windows XP 或更高版本的功能。
#define WINVER 0x0501 // 将此值更改为相应的值,以适用于 Windows 的其他版本。
#endif
#ifndef _WIN32_WINNT // 允许使用特定于 Windows XP 或更高版本的功能。
#define _WIN32_WINNT 0x0501 // 将此值更改为相应的值,以适用于 Windows 的其他版本。
#endif
#ifndef _WIN32_WINDOWS // 允许使用特定于 Windows 98 或更高版本的功能。
#define _WIN32_WINDOWS 0x0410 // 将它更改为适合 Windows Me 或更高版本的相应值。
#endif
#ifndef _WIN32_IE // 允许使用特定于 IE 6.0 或更高版本的功能。
#define _WIN32_IE 0x0600 // 将此值更改为相应的值,以适用于 IE 的其他版本。值。
#endif
#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS // 某些 CString 构造函数将是显式的
// 关闭 MFC 对某些常见但经常可放心忽略的警告消息的隐藏
#define _AFX_ALL_WARNINGS
#include <afxwin.h> // MFC 核心组件和标准组件
#include <afxext.h> // MFC 扩展
#include <afxdisp.h> // MFC 自动化类
#ifndef _AFX_NO_OLE_SUPPORT
#include <afxdtctl.h> // MFC 对 Internet Explorer 4 公共控件的支持
#endif
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC 对 Windows 公共控件的支持
#endif // _AFX_NO_AFXCMN_SUPPORT
#include <afxsock.h> // MFC 套接字扩展
#include <ole2.h> // OLE2 Definitions
#include <afxinet.h> // 网络组件
#import "C:\Program Files\Common Files\System\ado\msado15.dll" no_namespace rename ("EOF", "adoEOF") // 加入ADO支持库
#import "C:\WINDOWS\system32\msxml2.dll" // 加入msxml2运行库
using namespace MSXML2;
#import "C:\WINDOWS\system32\msscript.ocx" // msscript.ocx
using namespace MSScriptControl;
extern CString g_sExePath; // Exe执行路径
extern CString g_sSysFlag; // 系统标志位
extern CString g_sSysVersion; // 系统版本
extern CString g_sDBFlag; // 数据库类型0 Access 1 SQLServer 2 Oracle
extern CString g_sDBServerIP; // SQLServer数据库服务器
extern CString g_sDataBase; // SQLServer数据库名称
extern CString g_sUserName; // SQLServer数据库用户
extern CString g_sPassword; // SQLServer数据库用户密码
extern CString g_sAccessFile; // 数据库类型为Access的数据库文件
extern CString g_sOraDataSource; // Oracle数据库服务名称
extern CString g_sOraUser; // Oracle用户帐号
extern CString g_sOraPWD; // Oracle用户密码
extern CString g_sFtpIP; // Ftp服务器
extern CString g_sFtpPort; // Ftp端口
extern CString g_sFtpUser; // Ftp用户帐号
extern CString g_sFtpPWD; // Ftp用户密码
#ifdef _UNICODE
#if defined _M_IX86
#pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='x86' publicKeyToken='6595b64144ccf1df' language='*'\"")
#elif defined _M_IA64
#pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='ia64' publicKeyToken='6595b64144ccf1df' language='*'\"")
#elif defined _M_X64
#pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='amd64' publicKeyToken='6595b64144ccf1df' language='*'\"")
#else
#pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'\"")
#endif
#endif