daocontrol.h

来自「Visual C++ 数 据 库」· C头文件 代码 · 共 29 行

H
29
字号
#if !defined(__daocontrol_h)
#define __daocontrol_h

//This is the base class for control objects. They must inherit from this
//in addition to their MFC hierarchy.
//It manages database data retrieving and storing.

#define DAOCONTROL(name) m_##name = #name
					//Macro for initializing control objects

class DaoControl : public Field {
	virtual void Transfer(BOOL bSaveAndValidate) = 0;
		//This forces derived classes to implement the transfer mechanism.
protected:
	Variant index;
		//Attribute for the field class. It can be a field name or a field index.
	void DDX_Control(CDataExchange *pDX);
		//Binding method. It manages collaboration between the GUI 
		//and database components.
public:
	DaoControl();
	DaoControl& operator=(Variant const &);
		//Assignment operator. Each derived class must override this.
	virtual void Enable(bool e = true) = 0;
		//User interface enabling/disabling mandatory method.
};


#endif

⌨️ 快捷键说明

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