[Qt-qml] XML patterns and Namespace prefix
adrian hornsby
hornsby.adrian at gmail.com
Mon Nov 22 08:40:18 CET 2010
Hi all,
I am trying to parse an activity-stream:
<entry>
<id>tag:photopanic.example.com,2008:photo01</id>
<title>My Cat</title>
<published>2008-11-02T15:29:00Z</published>
<link rel="alternate" type="text/html"
href="/geraldine/photos/1" />
<activity:object-type>
tag:atomactivity.example.com,2008:photo
</activity:object-type>
</entry>
with QML XMLlistmodel and XMLrole as follows:
query: "/wall/entry"
XmlRole { name: "title"; query: "title/string()" }
XmlRole { name: "published"; query: "published/string()" }
XmlRole { name: "link"; query: "link/@href/string()" }
but get this error:
Error FODC0002 in
tag:trolltech.com,2007:QtXmlPatterns:QIODeviceVariable:src, at line 9,
column 25: Namespace prefix 'activity' not declared
any idea how to solve that. All work well if I use very simple XML docs.
thanks,
Adrian
More information about the Qt-qml
mailing list