Solved

Parsing xmlHTTP response from server in VB.NET

Posted on 2004-09-17
4
812 Views
Last Modified: 2007-12-19
Hi all,

I am using a VB.NET client to communicate with an ASP.NET web service. I am able to send an XML request via xmlHTTP and get a response back which I can display using xmlHTTP.responseXML.xml.

Whats the best way to parse this response from the server. I am trying to use xmlTextReader but it requires an xml file or a stream or a URL. What I have is xmlHTTP.responseXML. How can I use xmlTextReader function to parse xml from the responseXML. Or what are the alternatives available.

Dim reader As XmlTextReader = New XmlTextReader(xmlHTTP.responseXML.xml)

gave the following error

 Overload resolution failed because no accessible 'New' can be called without a narrowing conversion:
    'Public Sub New(url As String)': Argument matching parameter 'url' narrows from 'System.Object' to 'String'.
    'Public Sub New(input As System.IO.TextReader)': Argument matching parameter 'input' narrows from 'System.Object' to 'System.IO.TextReader'.
    'Public Sub New(input As System.IO.Stream)': Argument matching parameter 'input' narrows from 'System.Object' to 'System.IO.Stream'.

Regards,
Cannibal Corpse
0
Comment
Question by:Cannibal_Corpse
4 Comments
 
LVL 18

Accepted Solution

by:
armoghan earned 500 total points
Comment Utility
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

744 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

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now