NWCCOpenConnByPref
Opens an initial connection using the configured preferred settings
#include <nwclxcon.h>
N_EXTERN_LIBRARY NWRCODE NWCCOpenConnByPref (
nuint tranType,
nuint openState,
nuint reserved,
pNWCONN_HANDLE pConnHandle);
uses clxwin32
Function NWCCOpenConnByPref (
tranType : nuint;
openState : nuint;
reserved : nuint;
pConnHandle : pNWCONN_HANDLE
) : NWRCODE;
These are common return values; see Return Values (Return Values for C) for more information.
NWCCOpenConnByPref is similar to NWCCOpenConnByName, which uses the preferred server or preferred tree name, except that NWCCOpenConnByPref uses the configured preferences of the requester to establish an initial connection to a server.
NOTE:In the event that a connection to the preferred tree or server cannot be established, another connection may be returned.
NWCCOpenConnByPref will return NWE_CONN_INVALID if the platform being run is not Windows 95 since NWCCOpenConnByPref is only successful on Windows 95.