⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vbe6ext.tli

📁 word 插件 在word2003+ vc6.0 条件下运行 可以单击弹出atl 的窗口 简单可实现
💻 TLI
📖 第 1 页 / 共 4 页
字号:
inline void AddIn::PutObject ( IDispatch * lppdisp ) {
    HRESULT _hr = put_Object(lppdisp);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
}

//
// interface _CodeModule wrapper method implementations
//

inline _VBComponentPtr _CodeModule::GetParent ( ) {
    struct _VBComponent * _result;
    HRESULT _hr = get_Parent(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _VBComponentPtr(_result, false);
}

inline VBEPtr _CodeModule::GetVBE ( ) {
    struct VBE * _result;
    HRESULT _hr = get_VBE(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return VBEPtr(_result, false);
}

inline _bstr_t _CodeModule::GetName ( ) {
    BSTR _result;
    HRESULT _hr = get_Name(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _bstr_t(_result, false);
}

inline void _CodeModule::PutName ( _bstr_t pbstrName ) {
    HRESULT _hr = put_Name(pbstrName);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
}

inline HRESULT _CodeModule::AddFromString ( _bstr_t String ) {
    HRESULT _hr = raw_AddFromString(String);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline HRESULT _CodeModule::AddFromFile ( _bstr_t FileName ) {
    HRESULT _hr = raw_AddFromFile(FileName);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline _bstr_t _CodeModule::GetLines ( long StartLine, long Count ) {
    BSTR _result;
    HRESULT _hr = get_Lines(StartLine, Count, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _bstr_t(_result, false);
}

inline long _CodeModule::GetCountOfLines ( ) {
    long _result;
    HRESULT _hr = get_CountOfLines(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline HRESULT _CodeModule::InsertLines ( long Line, _bstr_t String ) {
    HRESULT _hr = raw_InsertLines(Line, String);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline HRESULT _CodeModule::DeleteLines ( long StartLine, long Count ) {
    HRESULT _hr = raw_DeleteLines(StartLine, Count);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline HRESULT _CodeModule::ReplaceLine ( long Line, _bstr_t String ) {
    HRESULT _hr = raw_ReplaceLine(Line, String);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline long _CodeModule::GetProcStartLine ( _bstr_t ProcName, enum vbext_ProcKind ProcKind ) {
    long _result;
    HRESULT _hr = get_ProcStartLine(ProcName, ProcKind, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline long _CodeModule::GetProcCountLines ( _bstr_t ProcName, enum vbext_ProcKind ProcKind ) {
    long _result;
    HRESULT _hr = get_ProcCountLines(ProcName, ProcKind, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline long _CodeModule::GetProcBodyLine ( _bstr_t ProcName, enum vbext_ProcKind ProcKind ) {
    long _result;
    HRESULT _hr = get_ProcBodyLine(ProcName, ProcKind, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline _bstr_t _CodeModule::GetProcOfLine ( long Line, enum vbext_ProcKind * ProcKind ) {
    BSTR _result;
    HRESULT _hr = get_ProcOfLine(Line, ProcKind, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _bstr_t(_result, false);
}

inline long _CodeModule::GetCountOfDeclarationLines ( ) {
    long _result;
    HRESULT _hr = get_CountOfDeclarationLines(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline long _CodeModule::CreateEventProc ( _bstr_t EventName, _bstr_t ObjectName ) {
    long _result;
    HRESULT _hr = raw_CreateEventProc(EventName, ObjectName, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline VARIANT_BOOL _CodeModule::Find ( _bstr_t Target, long * StartLine, long * StartColumn, long * EndLine, long * EndColumn, VARIANT_BOOL WholeWord, VARIANT_BOOL MatchCase, VARIANT_BOOL PatternSearch ) {
    VARIANT_BOOL _result;
    HRESULT _hr = raw_Find(Target, StartLine, StartColumn, EndLine, EndColumn, WholeWord, MatchCase, PatternSearch, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline _CodePanePtr _CodeModule::GetCodePane ( ) {
    struct _CodePane * _result;
    HRESULT _hr = get_CodePane(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _CodePanePtr(_result, false);
}

//
// interface _CodePanes wrapper method implementations
//

inline VBEPtr _CodePanes::GetParent ( ) {
    struct VBE * _result;
    HRESULT _hr = get_Parent(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return VBEPtr(_result, false);
}

inline VBEPtr _CodePanes::GetVBE ( ) {
    struct VBE * _result;
    HRESULT _hr = get_VBE(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return VBEPtr(_result, false);
}

inline _CodePanePtr _CodePanes::Item ( const _variant_t & index ) {
    struct _CodePane * _result;
    HRESULT _hr = raw_Item(index, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _CodePanePtr(_result, false);
}

inline long _CodePanes::GetCount ( ) {
    long _result;
    HRESULT _hr = get_Count(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline IUnknownPtr _CodePanes::_NewEnum ( ) {
    IUnknown * _result;
    HRESULT _hr = raw__NewEnum(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return IUnknownPtr(_result, false);
}

inline _CodePanePtr _CodePanes::GetCurrent ( ) {
    struct _CodePane * _result;
    HRESULT _hr = get_Current(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _CodePanePtr(_result, false);
}

inline void _CodePanes::PutCurrent ( struct _CodePane * CodePane ) {
    HRESULT _hr = put_Current(CodePane);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
}

//
// interface _CodePane wrapper method implementations
//

inline _CodePanesPtr _CodePane::GetCollection ( ) {
    struct _CodePanes * _result;
    HRESULT _hr = get_Collection(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _CodePanesPtr(_result, false);
}

inline VBEPtr _CodePane::GetVBE ( ) {
    struct VBE * _result;
    HRESULT _hr = get_VBE(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return VBEPtr(_result, false);
}

inline WindowPtr _CodePane::GetWindow ( ) {
    struct Window * _result;
    HRESULT _hr = get_Window(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return WindowPtr(_result, false);
}

inline HRESULT _CodePane::GetSelection ( long * StartLine, long * StartColumn, long * EndLine, long * EndColumn ) {
    HRESULT _hr = raw_GetSelection(StartLine, StartColumn, EndLine, EndColumn);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline HRESULT _CodePane::SetSelection ( long StartLine, long StartColumn, long EndLine, long EndColumn ) {
    HRESULT _hr = raw_SetSelection(StartLine, StartColumn, EndLine, EndColumn);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline long _CodePane::GetTopLine ( ) {
    long _result;
    HRESULT _hr = get_TopLine(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline void _CodePane::PutTopLine ( long TopLine ) {
    HRESULT _hr = put_TopLine(TopLine);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
}

inline long _CodePane::GetCountOfVisibleLines ( ) {
    long _result;
    HRESULT _hr = get_CountOfVisibleLines(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline _CodeModulePtr _CodePane::GetCodeModule ( ) {
    struct _CodeModule * _result;
    HRESULT _hr = get_CodeModule(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _CodeModulePtr(_result, false);
}

inline HRESULT _CodePane::Show ( ) {
    HRESULT _hr = raw_Show();
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

inline enum vbext_CodePaneview _CodePane::GetCodePaneView ( ) {
    enum vbext_CodePaneview _result;
    HRESULT _hr = get_CodePaneView(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

//
// interface _References wrapper method implementations
//

inline _VBProjectPtr _References::GetParent ( ) {
    struct _VBProject * _result;
    HRESULT _hr = get_Parent(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _VBProjectPtr(_result, false);
}

inline VBEPtr _References::GetVBE ( ) {
    struct VBE * _result;
    HRESULT _hr = get_VBE(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return VBEPtr(_result, false);
}

inline ReferencePtr _References::Item ( const _variant_t & index ) {
    struct Reference * _result;
    HRESULT _hr = raw_Item(index, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return ReferencePtr(_result, false);
}

inline long _References::GetCount ( ) {
    long _result;
    HRESULT _hr = get_Count(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline IUnknownPtr _References::_NewEnum ( ) {
    IUnknown * _result;
    HRESULT _hr = raw__NewEnum(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return IUnknownPtr(_result, false);
}

inline ReferencePtr _References::AddFromGuid ( _bstr_t Guid, long Major, long Minor ) {
    struct Reference * _result;
    HRESULT _hr = raw_AddFromGuid(Guid, Major, Minor, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return ReferencePtr(_result, false);
}

inline ReferencePtr _References::AddFromFile ( _bstr_t FileName ) {
    struct Reference * _result;
    HRESULT _hr = raw_AddFromFile(FileName, &_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return ReferencePtr(_result, false);
}

inline HRESULT _References::Remove ( struct Reference * Reference ) {
    HRESULT _hr = raw_Remove(Reference);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _hr;
}

//
// interface Reference wrapper method implementations
//

inline _ReferencesPtr Reference::GetCollection ( ) {
    struct _References * _result;
    HRESULT _hr = get_Collection(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _ReferencesPtr(_result, false);
}

inline VBEPtr Reference::GetVBE ( ) {
    struct VBE * _result;
    HRESULT _hr = get_VBE(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return VBEPtr(_result, false);
}

inline _bstr_t Reference::GetName ( ) {
    BSTR _result;
    HRESULT _hr = get_Name(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _bstr_t(_result, false);
}

inline _bstr_t Reference::GetGuid ( ) {
    BSTR _result;
    HRESULT _hr = get_Guid(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _bstr_t(_result, false);
}

inline long Reference::GetMajor ( ) {
    long _result;
    HRESULT _hr = get_Major(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline long Reference::GetMinor ( ) {
    long _result;
    HRESULT _hr = get_Minor(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline _bstr_t Reference::GetFullPath ( ) {
    BSTR _result;
    HRESULT _hr = get_FullPath(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _bstr_t(_result, false);
}

inline VARIANT_BOOL Reference::GetBuiltIn ( ) {
    VARIANT_BOOL _result;
    HRESULT _hr = get_BuiltIn(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline VARIANT_BOOL Reference::GetIsBroken ( ) {
    VARIANT_BOOL _result;
    HRESULT _hr = get_IsBroken(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline enum vbext_RefKind Reference::GetType ( ) {
    enum vbext_RefKind _result;
    HRESULT _hr = get_Type(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _result;
}

inline _bstr_t Reference::GetDescription ( ) {
    BSTR _result;
    HRESULT _hr = get_Description(&_result);
    if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this));
    return _bstr_t(_result, false);
}

//
// dispinterface _dispReferences_Events wrapper method implementations
//

inline HRESULT _dispReferences_Events::ItemAdded ( struct Reference * Reference ) {
    return _com_dispatch_method(this, 0x0, DISPATCH_METHOD, VT_EMPTY, NULL, 
        L"\x0009", Reference);
}

inline HRESULT _dispReferences_Events::ItemRemoved ( struct Reference * Reference ) {
    return _com_dispatch_method(this, 0x1, DISPATCH_METHOD, VT_EMPTY, NULL, 
        L"\x0009", Reference);
}

⌨️ 快捷键说明

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