473,888 Members | 1,521 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Geting remote XML file into DataSet or XmlDocument

I tried the code and it works without any probs. The prob
must be in your network. Maybe you have to reconfigure
your Firwall.

Sonu
http://weblogs.asp.net/sonukapoor/
-----Original Message-----
How do I load a remote xml file into the DateSet or into System.Xml.XmlD ocument on a WEB Application.
I tried these codes via c#:

System.Xml.Xml Document XmlBelge = new XmlDocument();
XmlBelge.Load( "http://blogs.msdn.com/ericgu/rss.aspx");

But I taked this error:
----------------------------
The underlying connection was closed: Unable to connect to the remote server.Description: An unhandled exception occurred during the execution of the current web request. Please review the
stack trace for more information about the error and where
it originated in the code.
Exception Details: System.Net.WebE xception: The underlying connection was closed: Unable to connect to the
remote server.
Source Error:
Line 61: {
Line 62: System.Xml.XmlD ocument XmlBelge =new XmlDocument();Line 63: XmlBelge.Load ("http://blogs.msdn.com/ericgu/rss.aspx");
-------------
I used DataSet.ReadXml ("URL") and XmlControl and the result was same with above: (The underlying connection was
closed: Unable to connect to the remote server. )
I can run it on Windows Application but I would like to run on Web Application.
I am working in a LAN and behind a firewall, and my system is: WinXP Pro, Framework 1.1, IIS 5.1
How can I resolve this problem.

Thanks.

Engin
.

Nov 12 '05 #1
1 4469
I had the same exact problem. Make sure you SP1 of the .NET Framework 1.1 - I installed it yesterday and the error was gone. It has something to do with the number of protocols that were bound to the network adapters on my machine. More than 50 protocols causes .NET to give me that error.

---
Posted using Wimdows.net NntpNews Component -

Post Made from http://www.SqlJunkies.com/newsgroups Our newsgroup engine supports Post Alerts, Ratings, and Searching.
Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
5771
by: Matt M | last post by:
Hey, I'm trying to pass an XML document from a webservice to another assembly. What I'd like to do is pass either an XML document or a dataset, so I figure that if I can turn the Dataset into an XMLDocument, then in my assembly, return that XMLDocument back to the dataset (if it is one), I will be good to go. Problem is, I haven't been able to find out how to transform a dataset into
3
9573
by: Tom Vukovich | last post by:
and returning the xml to the requesting web page, how do you insert the XML declaration? ds.EnforceConstraints = False Response.ContentType = "text/xml" ds.WriteXml(Response.OutputStream, XmlWriteMode.IgnoreSchema) I would like to add <?xml version="1.0" ?>
0
597
by: Sonu Kapoor | last post by:
I tried the code and it works without any probs. The prob must be in your network. Maybe you have to reconfigure your Firwall. Sonu http://weblogs.asp.net/sonukapoor/ >-----Original Message----- >How do I load a remote xml file into the DateSet or into System.Xml.XmlDocument on a WEB Application.
5
17710
by: Drew Yallop | last post by:
I read an XML file with a stream reader in VB.Net. When I look at the stream reader output in debug mode (by passing cursor over the stream reader object)the format is a perfect replica of the file as displayed when I open the xml file in VS .net 2003 IDE. When I perform the same procedure in C# the stream reader obkect displays a chaotic mess. Lots of whitespace after and "\r" and "\n" after each element. The problem is that I cannot...
5
10174
by: Rob Panosh | last post by:
Hello, I am trying to create a xmlDocument from as dataset. My code is listed below. All seems to go well until xmlDocument.Load(CType(ms, System.IO.Stream)) ... I keep getting the following error "The Root Element is Missing" ... any help would be appreciated. Thanks, Rob Panosh
1
3738
by: JoshKaos | last post by:
I am in the process of rewriting a WebService. The WebMethods are all returning XMLDocuments. First, they get a Dataset of records and then walk through the Dataset to populate the XMLDocument which is then passed to the Web application which then pushes the XMLDocument into a Dataset in order to use the data. Now my question is should I just skip the XMLDocument process and just pass the Dataset itself back from the WebService? Is...
7
3373
by: =?Utf-8?B?ZG91Zw==?= | last post by:
Have loaded balanced web servers that we do not allow to connect to our database. Content is created and pushed to these sites. I want to add a web service that may get multiple requests a second depending on peak access. I have built an XML file from SQL DB and pushed this file to web server. I want to load XML file at application startup and leave it cached if possible (it will vary in size from 1-2MB) and treat it like an SQL table...
5
1517
by: slinky | last post by:
I'm struggling with what should be a very basic .aspx/XML issue. I have an XML file. I have a textbox for a user to enter data and a button to submit the data. I don't wont the user to see the other records on the screen. I'm using Visual Web Developer Express 2005, vb.NET) I've tried several different strategies from books and online examples, but I can't seem to get anywhere. I'm guessing I need to Dim a DataSet (even though I'm adding...
6
2982
by: =?Utf-8?B?RGF2aWRN?= | last post by:
Hello, I have an XML file generated from a third party application that I would like to parse. Ideally, I plan on having a windows service setup to scan various folders for XML files and parse the file, then spit out totals. Since I haven't worked with XML too much in C#, I'm trying to develop a structured and easy-to-read way to parse the file. Essentially, I would like to read the file and add the "BatchTktAmountfor any...
11
2904
by: casucci | last post by:
I do a return as XMLDataDocument in my webservice but it returns not with the namespaces etc in them. Anyone have and example where I can have the webservice return it as a XML. C# preferred. Flash just sees it as an object when it calls the web service. Thanks
0
9961
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9800
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10778
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10886
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9597
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7990
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5819
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
6014
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
3252
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.