Solved

Help regarding Building a webservice

Posted on 2010-08-24
4
487 Views
Last Modified: 2013-11-19
Hi experts,

I need some help in building a webservice where I can consume another webservice which is returning data in the form of xml. Here I am able to call the service but I got stuck up with loading the data in the required format. One is get the required format I should be able to return this data back to client.  It is something like Client is calling a service which inturn call other service to retrieve data and return to client.
Format is something similar to this.

<parent1>
<childone/>
..
<parent1/>
<parent2>
<childone/>
..
<parent2/>
..........
..
.
.
.
.
.
.

So any help regarding building this service will be greatly appriciated.

Thanks,
AG
0
Comment
Question by:Anil Golamari
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 5

Accepted Solution

by:
Akin Delu earned 250 total points
ID: 33512516
why do you really need a webservice that calls another webservice, why not call the webservice from the application itself.
0
 
LVL 18

Author Comment

by:Anil Golamari
ID: 33512600
First web service is a wrapper, So now I need to build a web service where I can call the data from that wrapper. So now I should be able to get the required information instead of all the data from the service upto client.
0
 
LVL 36

Assisted Solution

by:Miguel Oz
Miguel Oz earned 250 total points
ID: 33526746
Consuming a web service from inside another web service is the same code as consuming from any other WCF client.
Check:
http://msdn.microsoft.com/en-us/library/bb332338.aspx
http://blogs.msdn.com/b/ericwhite/archive/2010/05/11/getting-started-building-a-wcf-web-service.aspx
http://www.xvpj.net/2008/03/08/wcf-step-by-step-tutorial/
http://www.switchonthecode.com/tutorials/wcf-tutorial-basic-interprocess-communication

Even though it is tempting to build a web method returning a XmlNode, your web service consumer has to do the hard work of parsing that information I will strongly suggest to use a serializable class, like ChildNode (implementation details is up to you) so your web method can return List<ChildNode>
0
 
LVL 18

Author Comment

by:Anil Golamari
ID: 33596908
None of the solution helped me. Anyhow thanks for your time to look into my issue.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question