GetAtomName function

Retrieves a copy of the character string associated with the specified local atom.

Syntax


UINT WINAPI GetAtomName(
  _In_   ATOM nAtom,
  _Out_  LPTSTR lpBuffer,
  _In_   int nSize
);

Parameters

nAtom [in]

Type: ATOM

The local atom that identifies the character string to be retrieved.

lpBuffer [out]

Type: LPTSTR

The character string.

nSize [in]

Type: int

The size, in characters, of the buffer.

Return value

Type: UINT

If the function succeeds, the return value is the length of the string copied to the buffer, in characters, not including the terminating null character.

If the function fails, the return value is zero. To get extended error information, call GetLastError.

Remarks

The string returned for an integer atom (an atom whose value is in the range 0x0001 to 0xBFFF) is a null-terminated string in which the first character is a pound sign (#) and the remaining characters represent the unsigned integer atom value.

Security Considerations

Using this function incorrectly might compromise the security of your program. Incorrect use of this function includes not correctly specifying the size of the lpBuffer parameter.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Winbase.h (include Windows.h)

Library

Kernel32.lib

DLL

Kernel32.dll

Unicode and ANSI names

GetAtomNameW (Unicode) and GetAtomNameA (ANSI)

See also

Reference
AddAtom
DeleteAtom
FindAtom
GlobalAddAtom
GlobalDeleteAtom
GlobalFindAtom
GlobalGetAtomName
MAKEINTATOM

 

 

Community Additions

ADD
Show:
© 2014 Microsoft