Microsoft KB Archive/303436

= How to use the new System.Net classes to create an HTTP client =

Article ID: 303436

Article Last Modified on 12/11/2006

-

APPLIES TO


 * Microsoft Visual C# .NET 2002 Standard Edition
 * Microsoft Visual C# 2005

-



This article was previously published under Q303436



SUMMARY
The CSharpHTTP.exe file sample that is provided through this article shows how to use the new System.Net classes to create an HTTP client that uses the HttpWebRequest and HttpWebResponse classes. This sample shows how to use the following HTTP verbs:
 * HEAD
 * GET
 * POST
 * PUT

It also demonstrates how to handle cookies and certificate errors when you use Secure Sockets Layer (SSL). This sample is based on the VBHTTP sample that is included with the Platform Software Development Kit (SDK).



MORE INFORMATION
The following file is available for download from the Microsoft Download Center:

CSharpHTTP.exe

Release Date: August 23, 2001

For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 How to obtain Microsoft support files from online services

Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file. The Csharphttp.exe file contains the following files:

Microsoft provides programming examples for illustration only, without warranty either expressed or implied, including, but not limited to, the implied warranties of merchantability and/or fitness for a particular purpose. This article assumes that you are familiar with the programming language being demonstrated and the tools used to create and debug procedures. Microsoft support professionals can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific needs. If you have limited programming experience, you may want to contact a Microsoft Certified Partner or the Microsoft fee-based consulting line at (800) 936-5200. For more information about Microsoft Certified Partners, please visit the following Microsoft Web site:

https://partner.microsoft.com/global/30000104

For more information about the support options that are available and about how to contact Microsoft, visit the following Microsoft Web site:

http://support.microsoft.com/default.aspx?scid=fh;EN-US;CNTACTMS

Additional query words: CSharpHTTP

Keywords: kbhowto kbdownload kbfile KB303436

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.