Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
peter_strange
Posts: 19,599
Registered: ‎07-14-2008
My Device: Not Specified
Accepted Solution

Error when building project with SAX XML processing.

[ Edited ]

I am developing some processing which uses the XML parser, in a very similar way to that used by the saxbookmarks sample.  I am struggling to get this to build

 

The first issue appears around the header - the documentation says, for example, for the QXmlDefaultHandler, that I need to include:

#include <QXmlDefaultHandler>

However that is not found and the compile fails.  So instead I use

#include <QtXml/QXmlDefaultHandler>

 

which seems to work.

 

However when i then build this code I get messages like the following in the console log:

XMLTableHandler.o: undefined reference to symbol '_ZNK18QXmlParseException7messageEv'

 

XMLTableHandler is my code

 

I can build the sample and have compared all the various settings that I can think off (pro file, SDK build level and so on) to make sure that they are the same.  But nothing stops this.

 

I can remove the error by rebuilding without the XMLTableHandler class.  I will try to cut out as much of its code as I can while still provoking the error and then post that code, but I suspect in fact there is something else in configuration that is causing the problem. I hope someone can tell me what.

 

TIA.

Please use plain text.
Developer
Zmey
Posts: 1,510
Registered: ‎12-18-2012
My Device: PlayBook, Z10, DAC

Re: Error when building project with SAX XML processing.

Looks like QtXml libs aren't linked.

Is the line
QT += xml
present in .pro file?

Andrey Fidrya, @zmeyc on twitter
Please use plain text.
Developer
peter_strange
Posts: 19,599
Registered: ‎07-14-2008
My Device: Not Specified

Re: Error when building project with SAX XML processing.

Is now and building just fine.  Thanks.

 

Did I miss the instructions to add this in?  Where were they?

Please use plain text.
Developer
Zmey
Posts: 1,510
Registered: ‎12-18-2012
My Device: PlayBook, Z10, DAC

Re: Error when building project with SAX XML processing.

It's mentioned in "More..." section of this page but it's easy to miss:

http://developer.blackberry.com/cascades/reference/qtxml.html#details

 


Andrey Fidrya, @zmeyc on twitter
Please use plain text.