CMGetTypeInfoCount

 (Available in 01 TS COM - TS_COM_DelegateIDispatch)

Purpose

Get TypeInfo count

Syntax

// See MSDN doc
oDIObject:CMGetTypeInfoCount( ... ) 

Arguments

pTypeInfoCount
INT PTR

Description

Get TypeInfo count

MSDN ==== IDispatch::GetTypeInfoCount Retrieves the number of type information interfaces that an object provides (either 0 or 1).

HRESULT GetTypeInfoCount( unsigned int FAR* pctinfo );

Parameter pctinfo Points to a location that receives the number of type information interfaces provided by the object. If the object provides type information, this number is 1; otherwise the number is 0.

Return Value The return value obtained from the returned HRESULT is one of the following:

Return value Meaning S_OK Success. E_NOTIMPL Failure.

Comments The function may return zero, which indicates that the object does not provide any type information. In this case, the object may still be programmable through IDispatch or a VTBL, but does not provide run-time type information for browsers, compilers, or other programming tools that access type information. This can be useful for hiding an object from browsers.

Returns

LONGINT, hResult

Source

METHOD CMGetTypeInfoCount( pTypeInfoCount AS INT PTR ) AS LONG PASCAL CLASS TS_DelegateIDispatch
LOCAL loRetVal AS LONG
   TSTrace Enter
   IF SELF:FInit
      #IFDEF TS_TRACETIMED_ENABLE
         _TS_TraceTimedEnter( TS_TT_SYM_EXTERNAL, TS_TT_SYM_IDISPATCH, #GetTypeInfoCount  ; ...
        ... )
      #ENDIF
      loRetVal:=SELF:_AIDispatch:GetTypeInfoCount(  ; ...
     ... pTypeInfoCount )
      #IFDEF TS_TRACETIMED_ENABLE
         _TS_TraceTimedLeave( TS_TT_SYM_EXTERNAL, TS_TT_SYM_IDISPATCH, #GetTypeInfoCount  ; ...
        ... )
      #ENDIF
   ELSE
      TSTrace Warning "!SELF:FInit"
      loRetVal:=E_FAIL
   END
   TSTrace Leave
RETURN loRetVal