CInternetSession::GetGopherConnection

CGopherConnection* GetGopherConnection( LPCTSTR pstrServer, LPCTSTR pstrUserName = NULL, LPCTSTR pstrPassword = NULL, INTERNET_PORT nPort = INTERNET_INVALID_PORT_NUMBER );
Throw ( CInternetException );

Return Value

A pointer to a CGopherConnection object. If the call fails, determine the cause of the failure by examining the thrown CInternetException object.

Parameters

pstrServer

A pointer to a string containing the gopher server name.

pstrUserName

A pointer to a string containing the user name.

pstrPassword

A pointer to a string containing the access password.

nPort

A number that identifies the TCP/IP port to use on the server.

Remarks

Call this member function to establish a new gopher connection and get a pointer to a CGopherConnection object.

GetGopherConnection connects to a gopher server, and creates and returns a pointer to a CGopherConnection object. It does not perform any specific operation on the server. If you intend to read or write data, for example, you must perform those operations as separate steps. See the classes CGopherConnection, CGopherFile, and CGopherFileFind for information about searching for files, opening files, and reading or writing to files. For information about browsing an FTP site, see the member function OpenURL. See the article Internet Programming with WinInet in Visual C++ Programmer’s Guide for steps in performing common gopher connection tasks.

CInternetSession OverviewClass MembersHierarchy Chart

See Also   CGopherConnection, CInternetSession::GetFtpConnection, CInternetSession::GetHttpConnection, CInternetSession::OpenURL