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 896173
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T14:41:10+00:00 2026-05-15T14:41:10+00:00

I have made a WCF service(service1.svc) have 2 methods. 1.GetData() 2.ProductDetails(string ProdId) Both returns

  • 0

I have made a WCF service(service1.svc) have 2 methods.

1.GetData()

2.ProductDetails(string ProdId)

Both returns a file in JSON format when i do this.

http://192.x.x.x/Demo/Service1.svc/GetData

http://192.x.x.x/Demo/Service1.svc/ProductDetails?prodId=P2

now i want to use these methods in Iphone.

& i call them as-

NSDictionary *arrayDict=[[NSDictionary alloc]init];

NSString *requestString = [NSString stringWithFormat:@"%@", [arrayDict JSONFragment], nil];
NSData *requestData = [NSData dataWithBytes: [requestString UTF8String] length: [requestString length]];    
NSString *url = [NSString stringWithFormat:@"http://192.x.x.x/Demo/Service1.svc/ProductDetails/prodId=%@",@"P2"];
NSLog(@"URL %@",url);
NSMutableURLRequest *request = [[NSMutableURLRequest alloc] initWithURL:[NSURL URLWithString:url]];
NSString *postLength = [NSString stringWithFormat:@"%d", [requestData length]];
[request setHTTPMethod: @"POST"];
[request setValue:postLength forHTTPHeaderField:@"Content-Length"];
[request setValue:@"application/json" forHTTPHeaderField:@"Content-Type"];
[request setHTTPBody: requestData];
theConnection = [[NSURLConnection alloc] initWithRequest:request delegate:self];

SO please tell me how to call this method[ProductDetails(string ProdId)] in Iphone

  • 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-15T14:41:11+00:00Added an answer on May 15, 2026 at 2:41 pm

    Check this out: Calling WCF Service from iPhone

    http://knowledgebaseworld.blogspot.com/2010/06/calling-wcf-service-from-iphone.html

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

Sidebar

Related Questions

I have a web service (WCF or ASMX doesn't matter)... I have made a
I have made a new windows service which works fine using barebone code (just
Background I have made a Web Service in Visual Studio, and I'm trying to
I have a WCF service and a Web application. Web application makes calls to
I have a Web application and a WCF service hosted on the same Windows
I have made a small log service that i want to publish to a
I have a WCF service running on the IIS with a ServiceHostFactory. It's running
I have a WCF service with a simple Gallio unit test that calls the
Hi All I have written a wcf service and hosted it on windows service.
I have a simple WCF service hosting on IIS6 on a server on the

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.