RasEnumEntries  2PUQZ6P 

The RasEnumEntries function lists all entry names in a remote access phone book.

DWORD RasEnumEntries (

    LPTSTR reserved,

// reserved, must be NULL

    LPTSTR lpszPhonebook,

// pointer to full path and filename of phone-book file

    LPRASENTRYNAME lprasentryname,

// buffer to receive phone-book entries

    LPDWORD lpcb,

// size in bytes of buffer

    LPDWORD lpcEntries

// number of entries written to buffer

   );

 

 

Parameters

reserved

Reserved; must be NULL.

lpszPhonebook

Windows NT: Pointer to a null-terminated string that specifies the full path and filename of a phone-book (.PBK) file. If this parameter is NULL, the function uses the current default phone-book file. The default phone-book file is the one selected by the user in the User Preferences property sheet of the Dial-Up Networking dialog box.

Windows 95: This parameter is ignored. Dial-up networking stores phone-book entries in the registry rather than in a phone-book file.

lprasentryname

Points to a buffer that receives an array of RASENTRYNAMEP.POVG structures, one for each phone-book entry. Before calling the function, an application must set the dwSize member of the first RASENTRYNAME structure in the buffer to sizeof(RASENTRYNAME) in order to identify the version of the structure being passed.

lpcb

Points to a variable that contains the size, in bytes, of the buffer specified by lprasentryname. On return, the function sets this variable to the number of bytes required to successfully complete the call.

lpcEntries

Points to a variable that the function, if successful, sets to the number of phone-book entries written to the buffer specified by lprasentryname.

 

Return Values

If the function succeeds, the return value is zero.

If the function fails, the return value is a nonzero error value listed in the RAS header file or one of ERROR_BUFFER_TOO_SMALL or ERROR_NOT_ENOUGH_MEMORY.

See Also

RASENTRYNAME, RasEnumConnections