//------------------------------------------------------------------- // VORecordset header file //------------------------------------------------------------------- // // Copyright ©2000 Virtual Office Systems Incorporated // All Rights Reserved // // This code may be used in compiled form in any way you desire. This // file may be redistributed unmodified by any means PROVIDING it is // not sold for profit without the authors written consent, and // providing that this notice and the authors name is included. // // This code can be compiled, modified and distributed freely, providing // that this copyright information remains intact in the distribution. // // This code may be compiled in original or modified form in any private // or commercial application. // // This file is provided "as is" with no expressed or implied warranty. // The author accepts no liability for any damage, in any form, caused // by this code. Use it at your own risk. //------------------------------------------------------------------- #if !defined(AFX_VORECORDSET_H__B81BD14E_98F0_42A7_A64F_3FA21F5A3E5D__INCLUDED_) #define AFX_VORECORDSET_H__B81BD14E_98F0_42A7_A64F_3FA21F5A3E5D__INCLUDED_ #if _MSC_VER > 1000 #pragma once #endif // _MSC_VER > 1000 #include #include #include "VOConnection.h" class CVORecordset { public: BOOL Delete(); BOOL SetFieldValue(LPCTSTR pcszFieldName, VARIANT varValue); BOOL SetFieldValue(int iField, VARIANT value); LPCTSTR GetFieldValueString(int iField); VARIANT GetFieldValue(int iField); LPCTSTR GetFieldName(int iField); Field* GetField(int iField); long GetFieldCount() { return m_FldCnt; } BOOL MoveNext(); BOOL MoveFirst(); BOOL IsEOF(); BOOL IsBOF(); BOOL Close(); BOOL Open(LPCTSTR pcszSource, enum CursorTypeEnum CursorType = adOpenForwardOnly, enum LockTypeEnum LockType = adLockReadOnly); BOOL Initialize(); BOOL IsOpen() { return m_fIsOpen; } CVORecordset(CVOConnection& rConn); virtual ~CVORecordset(); operator _Recordset*() { return m_rs; } protected: _variant_t m_varFieldValue; _variant_t m_varFieldName; BOOL m_fIsOpen; CVOConnection& m_rConn; _Recordset* m_rs; Fields* m_Fields; Field* m_Field; long m_FldCnt; static TCHAR* g_ProgID; static CLSID g_ClsID; static BOOL g_Init; }; #endif // !defined(AFX_VORECORDSET_H__B81BD14E_98F0_42A7_A64F_3FA21F5A3E5D__INCLUDED_)