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
New Developer
Posts: 23
Registered: ‎07-05-2013
My Device: Z10
My Carrier: Binus
Accepted Solution

How to implement QtSoap in native cascade development?

Hi there,

 

I want to ask you something about QtSoap implementation. I use QtSoap to parse *.asmx web services. I include qtsoap.h and qtsoap.cpp from external sources but i don't find the libraries.

Can you help me to solve this issues and how to implement QtSoap in native cascade?

 

thanks before.

 

I got this error message:

**** Build of configuration Simulator-Debug for project BB10BinusmayaMobile ****

make -j2 Simulator-Debug
make -C .//translations -f Makefile update
make[1]: Entering directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/translations'
D:/bbndk/host_10_1_0_132/win32/x86/usr/bin/lupdate BB10BinusmayaMobile.pro
Updating 'BB10BinusmayaMobile.ts'...
    Found 6 source text(s) (0 new and 6 already existing)
make[1]: Leaving directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/translations'
make -C .//translations -f Makefile release
make[1]: Entering directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/translations'
D:/bbndk/host_10_1_0_132/win32/x86/usr/bin/lrelease BB10BinusmayaMobile.pro
Updating 'D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/translations/BB10BinusmayaMobile.qm'...
    Generated 0 translation(s) (0 finished and 0 unfinished)
    Ignored 6 untranslated source text(s)
make[1]: Leaving directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/translations'
make -C ./x86 -f Makefile debug
make[1]: Entering directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
d:/bbndk/host_10_1_0_132/win32/x86/usr/bin/qmake.exe -spec ../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc CONFIG+=debug_and_release CONFIG+=simulator -o Makefile ../BB10BinusmayaMobile.pro
make[1]: Leaving directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
make[1]: Entering directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
make -f Makefile.Debug
make[2]: Entering directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
qcc -Vgcc_ntox86 -c -Wc,-include -Wc,o-g/.obj/BB10BinusmayaMobile -Wno-psabi -lang-c++ -fstack-protector -fstack-protector-all -g -Wno-psabi -Wall -W -D_REENTRANT -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -o o-g/.obj/applicationui.o ../src/applicationui.cpp
qcc -Vgcc_ntox86 -c -Wc,-include -Wc,o-g/.obj/BB10BinusmayaMobile -Wno-psabi -lang-c++ -fstack-protector -fstack-protector-all -g -Wno-psabi -Wall -W -D_REENTRANT -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -o o-g/.obj/main.o ../src/main.cpp
qcc -Vgcc_ntox86 -c -Wc,-include -Wc,o-g/.obj/BB10BinusmayaMobile -Wno-psabi -lang-c++ -fstack-protector -fstack-protector-all -g -Wno-psabi -Wall -W -D_REENTRANT -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -o o-g/.obj/qtsoap.o ../src/qtsoap.cpp
qcc -Vgcc_ntox86 -c -Wc,-include -Wc,o-g/.obj/BB10BinusmayaMobile -Wno-psabi -lang-c++ -fstack-protector -fstack-protector-all -g -Wno-psabi -Wall -W -D_REENTRANT -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -o o-g/.obj/webservices.o ../src/webservices.cpp
D:/bbndk/host_10_1_0_132/win32/x86/usr/bin/moc.exe -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -D__QNXNTO__ ../src/applicationui.hpp -o o-g/.moc/moc_applicationui.cpp
D:/bbndk/host_10_1_0_132/win32/x86/usr/bin/moc.exe -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -D__QNXNTO__ ../src/qtsoap.h -o o-g/.moc/moc_qtsoap.cpp
D:/bbndk/host_10_1_0_132/win32/x86/usr/bin/moc.exe -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -D__QNXNTO__ ../src/webservices.h -o o-g/.moc/moc_webservices.cpp
qcc -Vgcc_ntox86 -c -Wc,-include -Wc,o-g/.obj/BB10BinusmayaMobile -Wno-psabi -lang-c++ -fstack-protector -fstack-protector-all -g -Wno-psabi -Wall -W -D_REENTRANT -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -o o-g/.obj/moc_applicationui.o o-g/.moc/moc_applicationui.cpp
qcc -Vgcc_ntox86 -c -Wc,-include -Wc,o-g/.obj/BB10BinusmayaMobile -Wno-psabi -lang-c++ -fstack-protector -fstack-protector-all -g -Wno-psabi -Wall -W -D_REENTRANT -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -o o-g/.obj/moc_qtsoap.o o-g/.moc/moc_qtsoap.cpp
qcc -Vgcc_ntox86 -c -Wc,-include -Wc,o-g/.obj/BB10BinusmayaMobile -Wno-psabi -lang-c++ -fstack-protector -fstack-protector-all -g -Wno-psabi -Wall -W -D_REENTRANT -DQT_NO_IMPORT_QT47_QML -DQ_OS_BLACKBERRY -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/share/qt4/mkspecs/blackberry-x86-qcc -I../../BB10BinusmayaMobile -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtCore -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4/QtDeclarative -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/qt4 -I../src -Io-g/.moc -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include -I../../../../bbndk/target_10_1_0_1020/qnx6/usr/include/freetype2 -I. -o o-g/.obj/moc_webservices.o o-g/.moc/moc_webservices.cpp
qcc -Vgcc_ntox86 -lang-c++ -Wl,-rpath-link,D:/bbndk/target_10_1_0_1020/qnx6/x86/lib -Wl,-rpath-link,D:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib -Wl,-rpath-link,D:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib/qt4/lib -o o-g/BB10BinusmayaMobile o-g/.obj/applicationui.o o-g/.obj/main.o o-g/.obj/qtsoap.o o-g/.obj/test.o o-g/.obj/webservices.o o-g/.obj/moc_applicationui.o o-g/.obj/moc_qtsoap.o o-g/.obj/moc_test.o o-g/.obj/moc_webservices.o    -LD:/bbndk/target_10_1_0_1020/qnx6/x86/lib -LD:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib -LD:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib/qt4/lib -LD:/bbndk/target_10_1_0_1020/qnx6//usr/lib/qt4/lib -lbbcascades -lQtDeclarative -lQtScript -lQtSvg -lQtSql -lsqlite3 -lz -lQtXmlPatterns -lQtGui -lQtNetwork -lsocket -lQtCore -lm -lbps
D:\bbndk\host_10_1_0_132\win32\x86\usr\bin\ntox86-ld: o-g/.obj/qtsoap.o: undefined reference to symbol '_ZN12QDomDocument15createElementNSERK7QStringS2_'
D:\bbndk\host_10_1_0_132\win32\x86\usr\bin\ntox86-ld: note: '_ZN12QDomDocument15createElementNSERK7QStringS2_' is defined in DSO D:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib/qt4/lib/libQtXml.so.4 so try adding it to the linker command line
D:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib/qt4/lib/libQtXml.so.4: could not read symbols: Invalid operation
cc: D:/bbndk/host_10_1_0_132/win32/x86/usr/bin/ntox86-ld caught signal 1
make[2]: *** [o-g/BB10BinusmayaMobile] Error 1
make[1]: *** [debug] Error 2
make[2]: Leaving directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
make[1]: Leaving directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
make: *** [Simulator-Debug] Error 2

**** Build Finished ****

Developer
Posts: 16,997
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: How to implement QtSoap in native cascade development?

the h/cpp files are the library, there is no external lib file.
the compile error is due to an error in the pro file as it seems, something about qtxml according to the message.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
New Developer
Posts: 23
Registered: ‎07-05-2013
My Device: Z10
My Carrier: Binus

Re: How to implement QtSoap in native cascade development?

there is no error in the source codes or project's file but there is an error sign at the project's folder. I think the error is begin from the error message below but i don't understand where is the true error..

 

D:\bbndk\host_10_1_0_132\win32\x86\usr\bin\ntox86-ld: o-g/.obj/qtsoap.o: undefined reference to symbol '_ZN12QDomDocument15createElementNSERK7QStringS2_'
D:\bbndk\host_10_1_0_132\win32\x86\usr\bin\ntox86-ld: note: '_ZN12QDomDocument15createElementNSERK7QStringS2_' is defined in DSO D:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib/qt4/lib/libQtXml.so.4 so try adding it to the linker command line
make[2]: Leaving directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
make[1]: Leaving directory `D:/Document Training/ndk-10.1.0-workspace/BB10BinusmayaMobile/x86'
D:/bbndk/target_10_1_0_1020/qnx6/x86/usr/lib/qt4/lib/libQtXml.so.4: could not read symbols: Invalid operation
cc: D:/bbndk/host_10_1_0_132/win32/x86/usr/bin/ntox86-ld caught signal 1
make[2]: *** [o-g/BB10BinusmayaMobile] Error 1
make[1]: *** [debug] Error 2
make: *** [Simulator-Debug] Error 2

Highlighted
Developer
Posts: 16,997
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: How to implement QtSoap in native cascade development?

QDomDocument is part of QtXml, if you check that in the API docs
https://developer.blackberry.com/native/reference/cascades/qtxml.html
you see that:
To link against the module, add this line to your qmake .pro file:
QT += xml

try that.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
New Developer
Posts: 23
Registered: ‎07-05-2013
My Device: Z10
My Carrier: Binus

Re: How to implement QtSoap in native cascade development?

[ Edited ]

aww, thanks simon. It works very well. Info for everyone, there is case sensitive in the code. It must be what exactly simon said, QT += xml.

New Developer
Posts: 23
Registered: ‎07-05-2013
My Device: Z10
My Carrier: Binus

Re: How to implement QtSoap in native cascade development?

I got this error now, please someone can help me?

 

Server did not recognize the value of HTTP Header SOAPAction

 

how to solve this error using QtSoap? I try to use QtSoapMessage::useNamespace(prefix, uri) and using http://tempuri.org/ as default namespace, but i don't know what is prefix and uri in useNamespace parameter?

 

thanks before.

Developer
Posts: 16,997
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: How to implement QtSoap in native cascade development?

could you create a new thread for a new question?

the soap action is the method name of your webservice, for example getWeather. the parameter is only important for your server.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
New Developer
Posts: 23
Registered: ‎07-05-2013
My Device: Z10
My Carrier: Binus

Re: How to implement QtSoap in native cascade development?