473,386 Members | 1,766 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,386 software developers and data experts.

Invalid root element with C++ XML generation tool

MT
I have a very strange problem. I created an XSD file with the following
root:
<Database>
</Database>

However, since C++ does not allow you to have a property with the same name
as the class, when it generates the Strongly typed Dataset, it appends the
text "Schema" to the end of the root element. So the Strongly Typed class
name is DatabaseSchema. It does this by looking at the id property of the
schema.

However, this causes a lot of problems when I do a WriteXML on the dataset.
It basically generates this:
<?xml version="1.0" standalone="yes"?>

<DatabaseSchema xmlns="DatabaseSchema.xsd">

<Database>

</Database>

</DatabaseSchema>

instead of:

<?xml version="1.0" standalone="yes"?>

<Database xmlns="DatabaseSchema.xsd">

</Database>

This does not sound sound correct to me. Is this a known issue? Is there a
way around this?

Thanks,

MT


Nov 12 '05 #1
0 1500

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

Similar topics

12
by: pillepop2003 | last post by:
Hey! Can anyone give me a hint, how this problem is best implemented: I have a table of users (see below), where every user has one "superior user" (= parent node), this should be a fully...
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...
0
by: MT | last post by:
I have a very strange problem. I created an XSD file with the following root: <Database> </Database> However, since C++ does not allow you to have a property with the same name as the class,...
4
by: Mike | last post by:
I have a web service being consume by a new client. The WebMethod they are calling is called Process. So in the WSDL I have has 2 elements, Process and ProcessResponse. <s:schema...
0
by: John Jenkins | last post by:
Hi, can anyone shed some light on an issue I have encountered. I have used a tool (Cape Clear) to generate a WSDL file for me. When I use the WSDL2Java tool provided by apache axis it creates...
9
by: MR | last post by:
I get the following Exception "The data at the root level is invalid. Line 1, position 642" whenever I try to deserialize an incoming SOAP message. The incoming message is formed well and its...
2
by: John A Grandy | last post by:
I know that System.Security.SecurityElement.Escape() will replace invalid xml chars with valid equivalent ... But is there another method to accomplish same that is "closer to home" ?
4
by: johnsonkt | last post by:
hi all , when m trying to validate my xml using xsd file it gives me the following error "Data at the root level is invalid. Line 1, position 1" i tried to open the XML file using IE and there...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...

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.