ANY-maze Help > The ANY-maze reference > ANY-maze plug-ins > Plug-in API reference > AME_GETNAME message

AME_GETNAME message

The AME_GETNAME message is used to get a user-readable name for the plug-in. This is the name that will be displayed to the user, so it should be descriptive of what the plug-in does; however, you should try to keep the name concise as it is limited to 47 characters.

Parameters

guid

Pointer to the GUID of the plug-in whose name is being requested. If a DLL only implements a single plug-in, it can ignore this parameter - although it is good practice to always check it.

wParam

The size of the buffer pointed to by lParam, in bytes.

lParam

Pointer to a character buffer in which the name should be returned as a NULL-terminated ASCII string.

Return value

The only valid return codes from this message are:

 AME_OK 
 AME_ERROR 

If the code has written the name to the buffer, then return AME_OK.

If an error occurs, return AME_ERROR.

Remarks

In the following code, the DLL implements a single plug-in, whose name is held in the DLL's resource file.

  

  

//Check the GUID - not strictly necessary, but good practice

if (*guid != GUID_MYPLUGIN) return AME_ERROR;

  

//Load the name from the resource file

if (LoadString (hInstance, IDS_MYPLUGINNAME, (LPSTR)lParam, (int)wParam) == FALSE)

  return AME_ERROR;

else

  return AME_OK;

  

© Copyright 2003-2026 Stoelting Co. All rights reserved

ANY-maze help topic T1010