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

  • Home
  • SEARCH
  • 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 9229741
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T05:38:49+00:00 2026-06-18T05:38:49+00:00

In my app i am using SBJson for parsing the values. The web services

  • 0

In my app i am using SBJson for parsing the values. The web services are developed in dot net. With php web services the code was working quite fine but with dot net web services this is not showing the response values. There is no error or exception or warning in the code.

This is the JSON Output of the web service:

{ “Head”:[ { “id”:”0″,”msg”:”Username or Password Not Match”} ]}

the user name password is wrong here but my code is not even returning any wrong value.

This one is my code:

NSString *post = [NSString stringWithFormat:@"key=%@&username=%@&password=%@",key.text,[txtUsername text],[txtPassword text]];
NSLog(@"PostData: %@",post);

NSURL *url = [NSURL URLWithString:@"http://jabdcdfddfsd.aspx"];

NSData *postData = [post dataUsingEncoding:NSASCIIStringEncoding allowLossyConversion:YES];
NSLog(@"%@", postData);

NSString *postLength = [NSString stringWithFormat:@"%d", [postData length]];
NSLog(@"%@",postLength);
NSMutableURLRequest *request = [[NSMutableURLRequest alloc] init];
[request setURL:url];
[request setHTTPMethod:@"POST"];
[request setValue:postLength forHTTPHeaderField:@"Content-Length"];
[request setValue:@"application/json" forHTTPHeaderField:@"Accept"];
[request setValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
[request setHTTPBody:postData];

NSLog(@"%@",request);
NSError *error = [[NSError alloc] init];
NSHTTPURLResponse *response = nil;
NSData *urlData=[NSURLConnection sendSynchronousRequest:request returningResponse:&response error:&error];
NSLog(@"%@",response);

NSLog(@"Response code: %d", [response statusCode]);
if ([response statusCode] >=200 && [response statusCode] <300)
{
    NSString *responseData = [[NSString alloc]initWithData:urlData encoding:NSUTF8StringEncoding];
    NSLog(@"Response ==> %@", responseData)

Help Me Out. the responseData is printing nothing. There is any problem in my code or the problem is on other end i mean in dotnet web service.

  • 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-06-18T05:38:50+00:00Added an answer on June 18, 2026 at 5:38 am

    I think if the code worked fine with the old php webservice you should take a long hard look at your .Net webservice. It is highly likely that it is different in some respect. Try using something like the Chrome Advanced REST client to see how each webservice responds.

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

Sidebar

Related Questions

I wrote a php app using php+smarty. When I view the web source code
Currently i am working in iPhone app, Using SBJson, to parse Json response from
I'm working with a web service and using sbjson to parse received data like
I have an app using core data framework. I was working fine. I just
I'm developing web app using Spring Integration to route my messages, but I have
On a web app using GAS HtmlService I need to get the url of
I am writing an app using .NET, C#, LINQ to entities and SQL Server
Working on an app using Struts2, Tomcat 7 and an oracle database. Right now
On my web app using Java EE 6. I want to expose some of
I am using SBJson framework (also known as json-framework) for the iOS. When parsing

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.