Hardware Dev Center

IDebugControl2::GetTextReplacement method

The GetTextReplacement method returns the value of a user-named alias or an automatic alias.

Syntax


HRESULT GetTextReplacement(
  [in, optional]  PCSTR  SrcText,
  [in]            ULONG  Index,
  [out, optional] PSTR   SrcBuffer,
  [in]            ULONG  SrcBufferSize,
  [out, optional] PULONG SrcSize,
  [out, optional] PSTR   DstBuffer,
  [in]            ULONG  DstBufferSize,
  [out, optional] PULONG DstSize
);

Parameters

SrcText [in, optional]

Specifies the name of the alias. The engine first searches the user-named aliases for one with this name. Then, if no match is found, the automatic aliases are searched. If SrcText is NULL, Index is used to specify the alias.

Index [in]

Specifies the index of an alias. The indexes of the user-named aliases come before the indexes of the automatic aliases. Index is only used if SrcText is NULL. Index can be used along with GetNumberTextReplacements to iterate over all the user-named and automatic aliases.

SrcBuffer [out, optional]

Receives the name of the alias. This is the name specified in SrcText, if SrcText is not NULL. If SrcBuffer is NULL, this information is not returned.

SrcBufferSize [in]

Specifies the size, in characters, of the SrcBuffer buffer.

SrcSize [out, optional]

Receives the size, in characters, of the name of the alias. If SrcSize is NULL, this information is not returned.

DstBuffer [out, optional]

Receives the value of the alias specified by SrcText and Index. If DstBuffer is NULL, this information is not returned.

DstBufferSize [in]

Specifies the size, in characters, of the DstBuffer buffer.

DstSize [out, optional]

Receives the size, in characters, of the value of the alias. If DstSize is NULL, this information is not returned.

Return value

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

Return codeDescription
S_OK

The method was successful.

 

Remarks

Before executing commands or evaluating expressions, the debugger engine will replace the alias specified by SrcBuffer with the value of the alias (specified by DstBuffer).

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

Target platform

Desktop

Header

Dbgeng.h (include Dbgeng.h)

See also

IDebugControl2
IDebugControl3
SetTextReplacement
GetNumberTextReplacements
OutputTextReplacements
GetTextMacro
al (List Aliases)

 

 

Send comments about this topic to Microsoft

Show:
© 2015 Microsoft