473,716 Members | 2,520 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

What am I doing wrong? ("Debug" XML code help please.)

Hi,

xmllint --valid gives error output on some code (included below:)

file "Shotgun_Robot. dtd" (don't ask)

<!ELEMENT Image (#PCDATA) > <!-- #PCDATA == image path -->

<!-- x/y values default to 0, w/h values default to image w/h-->
<!ATTLIST Image
srcrect_x CDATA #IMPLIED
srcrect_y CDATA #IMPLIED
srcrect_w CDATA #IMPLIED
srcrect_h CDATA #IMPLIED

<!-- If element content is empty, the Drawable name points to an
already created Drawable. If it is not empty, it defines a
Drawable of the name and type given. -->
<!ELEMENT Drawable (EMPTY|Image|Mu p)
<!ATTLIST Drawable
name CDATA #REQUIRED


<!ELEMENT Mup (Drawable)* >
file "image_test.xml "

<?xml version="1.0"?>

<!DOCTYPE root SYSTEM "Shotgun_Robot. dtd" [
<!ELEMENT root ANY>
]>

<root>

<Drawable name="mup1">
<Mup>
<Drawable name="t43a">
<Image>images/sprites/tank_ClassicTra ckT43A.png</Image>
</Drawable>
<Drawable name="t43a" />
<Drawable name="mup1" />
</Mup>
</Drawable>

</root>
error output:

image_test.xml: 14: validity error: Element Drawable content does not
follow the DTD
Expecting (EMPTY | Image | Mup), got
<Drawable name="t43a" />
^
image_test.xml: 15: validity error: Element Drawable content does not
follow the DTD
Expecting (EMPTY | Image | Mup), got
<Drawable name="mup1" />
^
<?xml version="1.0"?>
<!DOCTYPE root SYSTEM "Shotgun_Robot. dtd" [
<!ELEMENT root ANY>
]>
<root>

<Drawable name="mup1">
<Mup>
<Drawable name="t43a">
<Image>images/sprites/tank_ClassicTra ckT43A.png</Image>
</Drawable>
<Drawable name="t43a"/>
<Drawable name="mup1"/>
</Mup>
</Drawable>

</root>
Wha??

Thanks,
Asfand Yar

--
http://www.it-is-truth.org/

Jul 20 '05 #1
2 2377
In article <bk**********@n ewsg4.svr.pol.c o.uk>,
Asfand Yar Qazi <im_not_giving_ it_here@i_hate_ spam.com> wrote:

% <!-- If element content is empty, the Drawable name points to an
% already created Drawable. If it is not empty, it defines a
% Drawable of the name and type given. -->
% <!ELEMENT Drawable (EMPTY|Image|Mu p)
% >
This says that Drawable takes one of three elements as content:
EMPTY, Image, or Mup. What you want is

<!ELEMENT Drawable (Image|Mup)?


This says that the content is zero or one of either Image or Mup.
--

Patrick TJ McPhee
East York Canada
pt**@interlog.c om
Jul 20 '05 #2
Patrick TJ McPhee wrote:
In article <bk**********@n ewsg4.svr.pol.c o.uk>,
Asfand Yar Qazi <im_not_giving_ it_here@i_hate_ spam.com> wrote:

% <!-- If element content is empty, the Drawable name points to an
% already created Drawable. If it is not empty, it defines a
% Drawable of the name and type given. -->
% <!ELEMENT Drawable (EMPTY|Image|Mu p)
% >
This says that Drawable takes one of three elements as content:
EMPTY, Image, or Mup. What you want is

<!ELEMENT Drawable (Image|Mup)?
>


This says that the content is zero or one of either Image or Mup.


(Sorry for the late reply...)

Ohh... now I see...

Thanks.

--
http://www.it-is-truth.org/

Jul 20 '05 #3

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

Similar topics

1
4436
by: asdf | last post by:
Hello, I was enjoying working in VS for half a year without any problems and now I cannot debug anymore. Without any really reason my Studio tells me that the page that I want to debug has - No symbols loaded. I use VS v1.7.3088 and .NET framework v1.1.4322 SP1. I work with ASP.NET using VB and I'm trying to set a breakpoint on the ascx.vb file.
4
4300
by: A_StClaire_ | last post by:
I read a section of my text on smart "counting" pointers and found it confusing so I decided to get hands-on. however I'm getting "Debug Assertion Failed... Expression: _BLOCK_TYPE_IS_VALID(pHead->nBlockUse)" whenever I run my code below. program works fine after I bypass the msg. any ideas? thx a lot.
10
28640
by: John Smith | last post by:
After reading C# documentation the Conditional attribute seemed the way to go, but after inspecting the IL it seems those methods are still there and I imagine the CLR removes them. Using #if DEBUG means the code does not even reach the IL when compiling in release mode. Is there any benefit to using the Conditional Attribute? Am I right in thinking there will small performance overhead using over #if DEBUG.
2
1689
by: Axel Dahmen | last post by:
Hi, when applying changes to the code and hitting to debug, a MessageBox pops up asking me if I want to build before debugging. Of course I want, that's why I've changed the code... Is there a simple way to suppress this MessageBox in Studio 7 and to start a Build-Debug sequence immediately? TIA, Axel Dahmen
1
5876
by: Alexander Walker | last post by:
Hello I have recently published a web application using the "Publish Web Site" option of the solution explorer from Visual Studio 2005, I have published the website so that the pages could not be updated, do I need to set the web.config so that it contains <compilation defaultLanguage="c#" debug="false"> before I publish the web site or can I make this configuration change on the deployment machine after the site has been deployed? ...
3
3108
by: André | last post by:
Hi, I put that question already, but it's still not very clear to me, so ... Assume following option in web.config= debug="false" but in one aspx page (test.aspx) <%@ debug="true" ..%>
2
2338
by: bbasberg | last post by:
Hello, I am a neophyte with Visual Basic but have been trying to hurry and get up to speed. I used to be able to "step into" code using Debug..step into but for the last couple of days I am unable to. Regardless of where in the code I place my cursor, I hear a microsoft error "thunk" and step into doesn't work. I am using VBA in Access if that matters. here's one possible clue but it may just be a coincidence: I tried some example...
2
1849
by: Joe Stateson | last post by:
I added ajax to an existing web project. It runs fine but hitting F5 (debug) in Visual Studio 2005 slowly consumes resources: Kernel Memory and System Cache grow and I start seeing "Loading symbols for C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\1.0.61025.0___\System.Web.Extensions.dll" in the VS2005 footer. After several hours of coding and debugging it can take 2 minutes before that "loading symbols" finally finishes. ...
1
3873
by: =?Utf-8?B?RWluYXY=?= | last post by:
hi, im developing a dll app under vs2005 (sp1). when trying to load my exe app (which uses the dll) im getting the following err message: "the application failed to initialize properly (0xc0000005)" im using a third party lib (qt 3.3.8) to create the gui. although eliminating it did solve to problem. im running in debug mode. i've used depends.exe and made sure all the dlls depend on the debug runtime dlls all depend on MSVCP80D.DLL and...
0
8823
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
8718
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
9344
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9200
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
9105
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,...
1
6647
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
5969
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
2
2543
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2119
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.