0 out of 2 rated this helpful - Rate this topic

InternetAttemptConnect function

Applies to: desktop apps only

Attempts to make a connection to the Internet.

Syntax

DWORD InternetAttemptConnect(
  __in  DWORD dwReserved
);

Parameters

dwReserved [in]

This parameter is reserved and must be 0.

Return value

Returns ERROR_SUCCESS if successful, or a system error code otherwise.

Remarks

This function allows an application to first attempt to connect before issuing any requests. A client program can use this to evoke the dial-up dialog box. If the attempt fails, the application should enter offline mode.

Like all other aspects of the WinINet API, this function cannot be safely called from within DllMain or the constructors and destructors of global objects.

Note  WinINet does not support server implementations. In addition, it should not be used from a service. For server implementations or services use Microsoft Windows HTTP Services (WinHTTP).

Requirements

Minimum supported client

Windows 2000 Professional

Minimum supported server

Windows 2000 Server

Header

Wininet.h

Library

Wininet.lib

DLL

Wininet.dll

See also

Enabling Internet Functionality
WinINet Functions

 

 

Send comments about this topic to Microsoft

Build date: 2/7/2012

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ