Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

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.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6878935
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T04:47:04+00:00 2026-05-27T04:47:04+00:00

Hi i need to post some data to a web server from windows phone

  • 0

Hi i need to post some data to a web server from windows phone 7 app, i have following url

someurl/devices.json

and i need to send two arguments with it

"externalDeviceId"  and "platform" as parameters

can any one let me know how to do it. i have been trying something like this

   WebClient client = new WebClient();
      client.UploadStringCompleted += new UploadStringCompletedEventHandler(webClient_UploadStringCompleted);
      client.Headers["Content-Type"] = "application/x-www-form-urlencoded";
      client.Encoding = Encoding.UTF8;
      string argument = "externalDeviceId=123456789987654321"+"&platform=wp7"
      client.UploadStringAsync(new Uri("someurl/devices.json"), "POST", argument);

but i get a web exception in the webClient_UploadStringCompleted callback.

i also tried something like this

soemurl/devices.json&externalDeviceId=123456789987654321&Platform=windowsphone7 but this is not working too get an error 404.

let me know where i am going wrong. this is on windows phone 7.

well it worked, if i comment out the header and encoding line it works

WebClient client = new WebClient();
client.UploadStringCompleted += new 
UploadStringCompletedEventHandler(webClient_UploadStringCompleted);
// client.Headers["Content-Type"] = "application/x-www-form-urlencoded";
 //client.Encoding = Encoding.UTF8;
 string argument = "externalDeviceId=123456789987654321"+"&platform=wp7"
 client.UploadStringAsync(new Uri("soemurl    
 /devices.json"), "POST", argument);

thanks Tetsujin no Oni san for helping … i was going in circles from last one day and just some discussion and it helped fixing this problem

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T04:47:05+00:00Added an answer on May 27, 2026 at 4:47 am

    With your API URI as given, what happens if you make your arguments actually follow the correct protocol for query string parameters?

    http://api.maxchatter.com/75b7bb32e5fc752546263a/devices.json?externalDeviceId=123456789987654321&Platform=windowsphone7

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to send some of my data into another server. Actually to post
I need to implement posting some data to a web server in the background.
I have a webservice that I need to POST some data to using Qt.
I need to post some text to a remote server over HTTP, this server
I'm running a Tomcat server with some virtual hosts and I need to POST
I need to POST data to a url in the middle of a script.
I've got a form and I need to post data to the server every
I am working on a ASP.NET app and i have a need to post
I need to transfer data from a PHP script on my local server to
I would like to invoke a webservice via Android. I need to POST some

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.