C# XML can't resolve entity, yet it exists



I'm parsing an XML file that contains entities. I receive the following exception:


Reference to undeclared entity 'deg'. Line 283, position 53.


This is my DOCTYPE:



<!DOCTYPE dmodule [
<!ENTITY % ISOEntities PUBLIC "ISO 8879-1986//ENTITIES ISO Character Entities 20030531//EN//XML" "ent/ISOEntities">
%ISOEntities;
]>


Inside the ISOEntities file I have this line:



<!ENTITY deg "&#x00B0;"> <!-- DEGREE SIGN -->


The entity definition exists. I don't understand why this particular entity is causing an error, when everything else is being resolved.


No comments:

Post a Comment