helpstring attribute

The [helpstring] attribute specifies a character string that is used to describe the element to which it applies. You can apply the [helpstring] attribute to library, importlib, interface, dispinterface, module, or coclass statements, typedefs, properties, and methods.

[
    helpstring(help-text-string)
    [, optional-attribute-list]
] 
element element-name
{
    definition
}

[idl-statement, helpstring(help-text-string)]

Parameters

help-text-string

A zero-terminated string of characters containing help text.

optional-attribute-list

Zero or more MIDL attribute statements.

element

One of the following directives: library, [importlib], interface, dispinterface, module, typedef, method, property, or coclass.

element-name

The name that other software components can use to delineate the current element

definition

Specifies statements that make up the element definition.

idl-statement

A MIDL interface definition statement such as propget or propput.

Remarks

Use the GetDocumentation functions in the ITypeLib and ITypeInfo interfaces to retrieve the help string.

Examples

[
    uuid(1e196b20-1f3c-1069-996b-00dd010fe676),
    helpstring("Lines 1.0 Type Library"),
    version(1.0)
]
library Lines
{
     [
         uuid(1e123456-1f3c-1069-996b-00dd010fe676), 
         helpstring("Line object."),
         oleautomation,
         dual
     ]
     interface ILine : IDispatch                         
     {
         [propget, helpstring("Returns and sets RGB color.")]
         HRESULT Color([out, retval] long* ReturnVal); 
         [propput, helpstring("Returns and sets RGB color.")]
         HRESULT Color([in] long rgb);
     }
};

See also

library

importlib

interface

dispinterface

module

coclass

typedef

ODL File Syntax

ODL File Example

Generating a Type Library With MIDL