Unsolved Signalling to QML based on 'id'
I have a Layout QML file which has several other nested sub-layout QMLs.
I have created a main.qml file, inside which I create two instances of Layout QML say "left" and "right".
I have two tcp client application which receives data from two different sources.
All I need to do is receive data from tcp client and signal it to the respective Layout QML.
Is there a way that I could use the QML 'id' and signal via my cpp program.
I have already referred topics: https://doc.qt.io/qt-5/qtqml-cppintegration-topic.html
https://doc.qt.io/qt-5/qtqml-cppintegration-topic.html and https://doc.qt.io/qt-5/qtqml-cppintegration-interactqmlfromcpp.html#connecting-to-qml-signals
Thanks in advance.
IntruderExcluder last edited by
You can set
objectNameto any item in QML and then use
findChildmethod of QObject on C ++ side. But it looks like you shold reconsider app architecture, something like controller is would be useful to your app.