Skip to content

VarSupports

Check if a variant supports an interface.

Declaration

Source position: variants.pp line 115

  function VarSupports(const V: Variant; const IID: TGuid; out Intf)
                       : Boolean;
  function VarSupports(const V: Variant; const IID: TGuid) : Boolean;

Description

VarSupports checks if the variant V contains an interface (types Unknown, varDispatch) and the interface supports the specified interface IID. If it does, True is returned, False otherwise. If Intf is specified, and the variant supports the requested interface, the interface instance is returned in Intf.

See also

Name Description
#rtl.sysutils.Supports Check whether a class or given interface supports an interface