473,320 Members | 2,003 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

invalid name with XSD, XML, and DataSet

I understand it is possible to take a valid schema & the XML data and load a data set. The XSD I use in another program to deserialize & serialize my XML.

But when I try this code I get this error message ... how do I fix it ?? I dont see a name for the DataSet ds
and as I see it, the table must be grabbing the name from the XML schema

{"The name 'transactions' is invalid. A DataSet cannot have the same name of the DataTable."

DataSet ds = new DataSet()
try

FileStream finschema= new FileStream(schemaPath,FileMode.Open,FileAccess.Rea d,FileShare.Read)
ds.ReadXmlSchema(finschema);
finschema.Close()

FileStream findata= new FileStream( dataPath,FileMode.Open,FileAccess.Read,FileShare.R ead)
ds.ReadXmlSchema(findata); // error here..
findata.Close()
catch (Exception e

Console.WriteLine(e.Message)

return ds

Thanks Andrew
Nov 16 '05 #1
0 1212

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

Similar topics

3
by: Sunny | last post by:
Hi, I'm using VS.net 2003 and C#. I created (using buildin designer) a dataset with 2 tables. TableOne has 2 fields: sName and sTable (both string) and a primary key TestKey, set on sName....
1
by: Dave | last post by:
Hi all, I've seen that many people have had this exact same problem in the past, but no-one seems to post the answer when (if) they solve it... so here we go again. If I create a strongly...
1
by: jk | last post by:
I need help in writing a datatable as xml in an aspx page. I have an excel client that opens the response as a stream into a recordset. In converting this code to .net c# from asp vb (where is used...
0
by: Deep Purple | last post by:
I started with the following error... ------------------------------------------------------- An error occured while loading the schema with TargetNamespace 'http://www.w3.org/2001/XMLSchema'...
3
by: Reb | last post by:
Hi, I am using MSSQL server 2000. When i am running my code, i am getting the error System.Data.SqlClient.SqlException: Invalid object name 'Item' where Item is the name of a table. It seems...
0
by: andrewcw | last post by:
I understand it is possible to take a valid schema & the XML data and load a data set. The XSD I use in another program to deserialize & serialize my XML. But when I try this code I get this error...
3
by: Anders Jansson | last post by:
Hi all. I have 2 problems when I try to open and convert an ASP.NET VS 2003 web-applikation in VS 2005. In VS 2003 I have no problems at all! First: One subfolder with will not be converted!...
0
by: Antonio | last post by:
Hello, everyone. I am getting an "Invalid CurrentPageIndex value. It must be >= 0 and < the PageCount." error message when I click on the Edit button on any pages in the datagrid besides the first...
1
mahet
by: mahet | last post by:
Anders Jansson was a guest here, and he was having problem: When I try to build the web, this error is displayed: ---> Error 5 Unable to convert input xml file content to a DataSet. Invalid...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

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.