Click here to Skip to main content
15,911,360 members
Home / Discussions / C#
   

C#

 
GeneralRe: Need help to write multiple columns of data from listview row to a single text file record Pin
Luc Pattyn4-Jul-09 12:09
sitebuilderLuc Pattyn4-Jul-09 12:09 
GeneralRe: Need help to write multiple columns of data from listview row to a single text file record Pin
DaveyM694-Jul-09 21:57
professionalDaveyM694-Jul-09 21:57 
GeneralRe: Need help to write multiple columns of data from listview row to a single text file record Pin
Robert Bone4-Jul-09 12:10
Robert Bone4-Jul-09 12:10 
QuestionWrite a save repport on txt file Pin
abbd4-Jul-09 8:31
abbd4-Jul-09 8:31 
AnswerRe: Write a save repport on txt file Pin
Colin Angus Mackay4-Jul-09 8:39
Colin Angus Mackay4-Jul-09 8:39 
AnswerRe: Write a save repport on txt file Pin
Anthony Mushrow4-Jul-09 8:44
professionalAnthony Mushrow4-Jul-09 8:44 
QuestionDrag & Drop problem Pin
ADRENALIN20064-Jul-09 7:27
ADRENALIN20064-Jul-09 7:27 
AnswerRe: Drag & Drop problem Pin
Luc Pattyn4-Jul-09 8:21
sitebuilderLuc Pattyn4-Jul-09 8:21 
GeneralRe: Drag & Drop problem Pin
ADRENALIN20065-Jul-09 5:09
ADRENALIN20065-Jul-09 5:09 
QuestionSplitting string in blocks of 16 Pin
GauravKP4-Jul-09 2:37
professionalGauravKP4-Jul-09 2:37 
AnswerRe: Splitting string in blocks of 16 Pin
Colin Angus Mackay4-Jul-09 2:45
Colin Angus Mackay4-Jul-09 2:45 
QuestionDataGrid showing multiple columns in C# 2003 [modified] Pin
Viper-Eyes4-Jul-09 2:08
Viper-Eyes4-Jul-09 2:08 
QuestionHttp Header code (example 200,404,..) Pin
Nafiseh Salmani3-Jul-09 22:33
Nafiseh Salmani3-Jul-09 22:33 
I want to determine HTTP header code of a URL by C# code. How could I get that?

I use the following code :
<br />
public Dictionary<string, string> GetHTTPResponseHeaders(string Url)<br />
        {<br />
            Dictionary<string, string> HeaderList = new Dictionary<string, string>();<br />
<br />
            WebRequest WebRequestObject = HttpWebRequest.Create(Url);<br />
            WebResponse ResponseObject = WebRequestObject.GetResponse();<br />
<br />
            foreach (string HeaderKey in ResponseObject.Headers)<br />
            {<br />
                HeaderList.Add(HeaderKey, ResponseObject.Headers[HeaderKey]);<br />
                textBox1.Text += HeaderKey + ": " + ResponseObject.Headers[HeaderKey]+"      " ;<br />
            }<br />
            ResponseObject.Close();<br />
<br />
            return HeaderList;<br />
}<br />


but It does not contain of HTTP header Code!
AnswerRe: Http Header code (example 200,404,..) Pin
Colin Angus Mackay4-Jul-09 1:08
Colin Angus Mackay4-Jul-09 1:08 
QuestionRe: Http Header code (example 200,404,..) Pin
Nafiseh Salmani4-Jul-09 1:36
Nafiseh Salmani4-Jul-09 1:36 
AnswerRe: Http Header code (example 200,404,..) Pin
Henry Minute4-Jul-09 1:46
Henry Minute4-Jul-09 1:46 
JokeRe: Http Header code (example 200,404,..) Pin
Colin Angus Mackay4-Jul-09 2:18
Colin Angus Mackay4-Jul-09 2:18 
GeneralRe: Http Header code (example 200,404,..) Pin
Henry Minute4-Jul-09 3:28
Henry Minute4-Jul-09 3:28 
GeneralRe: Http Header code (example 200,404,..) Pin
Nafiseh Salmani4-Jul-09 4:17
Nafiseh Salmani4-Jul-09 4:17 
QuestionGet Error Number in C# Pin
Anubhava Dimri3-Jul-09 22:19
Anubhava Dimri3-Jul-09 22:19 
AnswerRe: Get Error Number in C# Pin
DaveyM693-Jul-09 22:37
professionalDaveyM693-Jul-09 22:37 
GeneralRe: Get Error Number in C# Pin
Anubhava Dimri4-Jul-09 1:33
Anubhava Dimri4-Jul-09 1:33 
GeneralRe: Get Error Number in C# Pin
Colin Angus Mackay4-Jul-09 2:31
Colin Angus Mackay4-Jul-09 2:31 
GeneralRe: Get Error Number in C# Pin
Anubhava Dimri4-Jul-09 2:37
Anubhava Dimri4-Jul-09 2:37 
GeneralRe: Get Error Number in C# Pin
DaveyM694-Jul-09 5:09
professionalDaveyM694-Jul-09 5:09 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.