Visual Basic 6.0 Internet Programming.pdf

(3460 KB) Pobierz
To access the contents, click the chapter and section titles.
Visual Basic 6.0 Internet Programming
(Publisher: John Wiley & Sons, Inc.)
Author(s): Carl Franklin
ISBN: 0471314986
Publication Date: 02/01/99
Search this book:
CHAPTER 1—THE INTERNET
Attack of the Buzzwords!
Protocols and Data
Protocol Stacks and the OSI Model
TCP/IP
Names and Addresses
Ports
Name Resolution
Sockets
The TCP/IP Model
CHAPTER 2—WINSOCK PROGRAMMING
Introduction
Why Not Use the Winsock API?
Installing the Software
Loading DSSOCK32.OCX into Visual Basic
DSSOCK.BAS
SocketConnect
IsDotAddress
ParseString
Getting Started with dsSocket
Making a Sockets Connection
822191870.018.png 822191870.019.png 822191870.020.png 822191870.021.png 822191870.001.png 822191870.002.png 822191870.003.png 822191870.004.png 822191870.005.png 822191870.006.png 822191870.007.png 822191870.008.png 822191870.009.png 822191870.010.png 822191870.011.png 822191870.012.png 822191870.013.png
What’s Going On Here?
SocketID and the Socket Property
Closing the Connection
Handling Multiple Connections on the Server Side
Sending Data
Receiving Data
LineMode, EOLChar, and DataSize
The Simple Approach
A New Twist
Splitting Up the Process with Flags
A Slight Variation
Event Driven = No Loops
Which Approach Is Better?
Error Handling
Winsock Errors
Error-Handling Techniques
Minimal Error Trapping
Debug.Print Error Trapping
Message Dialog Reporting
Error Log Reporting
UDP—User Datagram Protocol
Terminal—A Winsock Terminal Program
Epilogue
CHAPTER 3—SIMPLE PROTOCOLS
Introduction
NTP (Network Time Protocol)
WHOIS
FINGER
SetTime Application
Epilogue
CHAPTER 4—USENET NEWS
Introduction
NNTP
More free ebooks : http://fast-file.blogspot.com
822191870.014.png
MessageIDs vs. Message Numbers
NNTP Versions
NNTP Commands
Sample Conversation
The WILDMAT Format
Server Responses
VB Programming Technique
The szParseString Function
Sample Program—NNTP.VBP
Connecting to an NNTP Server
Retrieving a Complete Article
Retrieving Article Information
Posting an Article
Posting a Reply to a Previous Message
LIST ACTIVE Returns Selective Newsgroups
XGTITLE Returns Newsgroup Descriptions
LIST NEWSGROUPS also Returns Newsgroup
Descriptions
Retrieving a Specific Header Field
Searching for Articles by Header
Server-to-Server Communication
Using the cfNNTP Object
Epilogue
CHAPTER 5—ELECTRONIC MAIL
Introduction
The SMTP Protocol
SMTP Commands
Server Responses
More free ebooks : http://fast-file.blogspot.com
822191870.015.png
Reply Code Categories
VB Programming Technique
Brain-Dead SMTP
True SMTP
Connecting and Disconnecting
Sample Application: SMTP.VBP
Sending Mail
Sending versus Mailing
Replying to Mail
Forwarding Mail
Verifying an SMTP Address
Error Handling
Post Office Protocol 3 (POP3)
POP3 Commands
Server Responses
POP3 States
Authorization State
Transaction State
Update State
VB Programming Technique
Sample Program: POP3.VBP
Logging into the Server
Retrieving Message Headers
Retrieving Messages
Sending and Receiving Binary Files
How UU Encoding Works
UUCODE.BAS Encoding and Decoding Routines
UUEncode
UUDecode
Sending an Encoded File with SMTP
nSendFileAsMsg
Using the cfSMTP and cfPOP3 Objects
Epilogue
CHAPTER 6—FILE TRANSFER PROTOCOL
Introduction
More free ebooks : http://fast-file.blogspot.com
822191870.016.png
When Should You Use FTP?
The FTP Program
Connecting and Logging In
Listing Directories
Changing Directories
Downloading
Uploading
Supported Commands
Ending the Session
Using a Web Browser to Download Files
The FTP Protocol
FTP Errata
Connections
FTP Commands
Server Responses
Reply Code Categories
Visual Basic Code
Using a Display Terminal
FTPLogon
SendFTPCommand
Retrieving a Directory Listing
Changing Directories
Downloading a File
GetFileFromURL
Uploading a File
Debugging
Inside the FTP Code
Connecting to the Server
Reality Break
Inside SendFTPCommand
Changing Directories
Creating a Data Connection
Retrieving a Directory Listing
Unix Wildcards
Uploading a File
Downloading a File
Using the cfFTP Object
More free ebooks : http://fast-file.blogspot.com
822191870.017.png
Zgłoś jeśli naruszono regulamin