Debugging Tools for Windows

GetTextMacro

The GetTextMacro and GetTextMacroWide methods return the value of a fixed-name alias.

HRESULT
  IDebugControl::GetTextMacro(
    IN ULONG  Slot,
    OUT OPTIONAL PSTR  Buffer,
    IN ULONG  BufferSize,
    OUt OPTIONAL PULONG  MacroSize
    );

HRESULT
  IDebugControl4::GetTextMacroWide(
    IN ULONG  Slot,
    OUT OPTIONAL PWSTR  Buffer,
    IN ULONG  BufferSize,
    OUt OPTIONAL PULONG  MacroSize
    );

#ifdef UNICODE
#define GetTextMacroT GetTextMacroWide
#else
#define GetTextMacroT GetTextMacro
#endif

Parameters

Slot
Specifies the number of the fixed-name alias. Slot can take the values 0, 1, …, 9, that represent the fixed-name aliases $u0, $u1, …, $u9.
Buffer
Receives the value of the alias specified by Slot. If Buffer is NULL, this information is not returned.
BufferSize
Specifies the size, in characters, of the Buffer buffer.
MacroSize
Receives the size, in characters, of the value of the alias.

Return Value

S_OK
The method was successful.

This method may also return error values. See Return Values for more details.

Interface Version

GetTextMacro is available in all versions of IDebugControl. GetTextMacroWide is available in IDeubgControl4 and later versions.

Comments

Before executing commands or evaluating expressions, the debugger engine will replace the alias specified by Slot with the value of the alias (returned to the Buffer buffer).

For an overview of aliases used by the debugger engine, see Using Aliases. For more information about using aliases with the debugger engine API, see Interacting with the Engine.

Requirements

Headers: Defined in Dbgeng.h. Include Dbgeng.h.

See Also

SetTextMacro, GetTextReplacement, GetNumberTextReplacements, r (Registers)

Build machine: CAPEBUILD