RasCreatePhonebookEntryA function (ras.h)
[This function has been deprecated as of Windows Vista and its functionality has been replaced by RasDialDlg. ]
The RasCreatePhonebookEntry function creates a new phone-book entry. The function displays a dialog box in which the user types information for the phone-book entry.
DWORD RasCreatePhonebookEntryA( HWND , LPCSTR );
Handle to the parent window of the dialog box.
Pointer to a null-terminated string that specifies the full path and file name 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.
If the function succeeds, the return value is ERROR_SUCCESS.
If the function fails, the return value is one of the following error codes or a value from Routing and Remote Access Error Codes or Winerror.h.
||The phone book is corrupted or missing components.|
When calling RasDialDlg, set each member of the RASDIALDLG structure passed to lpInfo to zero except:
- dwSize = sizeof(RASDIALDLG)
- hwndOwner = the hwnd parameter above
- dwFlags = RASEDFLAG_NewEntry
The ras.h header defines RasCreatePhonebookEntry as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
|Minimum supported client||Windows 2000 Professional [desktop apps only]|
|Minimum supported server||Windows 2000 Server [desktop apps only]|