autotype.odl

来自「The code for this article was written fo」· ODL 代码 · 共 48 行

ODL
48
字号
// AutoType.Odl

#ifndef _AUTOTYPE_ODL_
#define _AUTOTYPE_ODL_

#ifndef _WINTYPE_ODL_
#include <WinTypes.Odl>
#endif

// Fake constant BSTR because ODL has no const
#define BCSTR			BSTR		

// Give Basic names to OLE types
// typedef boolean         Boolean;
// typedef BYTE            Byte;
typedef short           Integer;
// typedef long            Long;
typedef float           Single;
// typedef double          Double;
// typedef LONGLONG        Currency;
typedef BSTR			String;
// typedef DATE            Date;
typedef IDispatch*      Object;

// Future compatibility with MIDL, in which boolean is unsigned char
#ifdef __midl
#define Boolean VARIANT_BOOL
#endif

// Defines for SafeArray definitions
#define ArrayByte		SAFEARRAY(Byte) *	
#define ArrayInteger	SAFEARRAY(short) *	
#define ArrayLong   	SAFEARRAY(long) *	
#define ArraySingle 	SAFEARRAY(float) *	
#define ArrayDouble 	SAFEARRAY(double) *	
#define ArrayCurrency	SAFEARRAY(Currency) *	
#define ArrayDate		SAFEARRAY(Date) *	
//@B ArrayString
#define ArrayString		SAFEARRAY(BSTR) *
//@E ArrayString
#define ArrayBoolean	SAFEARRAY(Boolean) *
#define ArrayObject		SAFEARRAY(IDispatch*) *
#define ArrayVariant	SAFEARRAY(Variant) *

#define ParamArray		SAFEARRAY(Variant) *

#endif // _AUTOTYPE_ODL_

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?