What is the easiest way to submit an HTTP POST request with a multipart/form-data content type from C#? There has to be a better way than building my own request.
The reason I’m asking is to upload photos to Flickr using this api:
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
First of all, there’s nothing wrong with pure manual implementation of the HTTP commands using the .Net framework. Do keep in mind that it’s a framework, and it is supposed to be pretty generic.
Secondly, I think you can try searching for a browser implementation in .Net. I saw this one, perhaps it covers the issue you asked about. Or you can just search for “C# http put get post request“. One of the results leads to a non-free library that may be helpful (Chilkat Http)
If you happen to write your own framework of HTTP commands on top of .Net – I think we can all enjoy it if you share it 🙂