I am porting my company application from Fivewin 2012 and Xharbour 1.2.1 to Fivewin 2015 and Xharbour 1.2.3.
I am searching for a solution to the following XML error: Invalid character as tag name. (The application with Fivewin 2012 and Xharbour 1.2.1 does not give such an error, only the new application with Fivewin 2015 and Xharbour 1.2.3 gives this error)
The code looks like this.
- Code: Select all Expand view RUN
- CLASS KddXmlDocument FROM TXmlDocument
#include <hbxml.ch>
#include <hbclass.ch>
PUBLIC:
METHOD New CONSTRUCTOR
METHOD toString
METHOD write
ENDCLASS
METHOD New( cXml,nStyle ) CLASS KddXmlDocument
super:new( cXML,nStyle )
IF ::nError <> HBXML_ERROR_NONE
msginfo( "XML:" + P_LICENTIE + cXML + CRLF + HB_XmlErrorDesc( ::nError ) + Str( ::nLine) )
msginfo( "XML:" + HB_XmlErrorDesc( ::nError ) ) //gives: Invalid character as tag name
msginfo( "XML:" + Str( ::nLine) ) //gives: 1
ENDIF
RETURN Self
Maybe somebody knows what could be the problem or have some ideas in what direction I best can search. I think it has something to do with (x)harbour (and not with fivewin), because I found the error description (Invalid character as tag name) in hbxml.c (in source code of Xharbour: C:\Pieter\xharbour_snapshot\source\rtl\)
- Code: Select all Expand view RUN
static const char * edesc[] =
{
"Input/output error",
"Not enough memory",
"Character outside tags",
"Invalid character as tag name",
"Invalid character as attribute name",
"Malformed attribute definition",
"Invalid character",
"Name of tag too long",
"Name of attribute too long",
"Value of attribute too long",
"Unbalanced tag closeure",
"Unbalanced entity opening",
"Escape/entity '&;' found"
};
Kind regards,
Pieter