TreeView unknown component (M300) - Qt5.5.1



  • I am Using treeview in qml, but the qtcreator says that it is an unknown component (m300)..i have import QtQuick.Controls 1.4

    so what do I have to do reinstall the qt liberary? or is there another way to solve?

    import QtQuick 2.5
    import QtQuick.Controls 1.4
    import QtQuick.Window 2.2
    import QtQuick.Dialogs 1.2
    import treeview.mymodels 1.0

    ApplicationWindow {
    title: qsTr("Qt Quick: TreeView")
    width: 640
    height: 480
    visible: true

    TabView {
        width: parent.width
        height: parent.height
        MyTreeModel {
            id: theModel
        }
        
        TreeView {
            id:treeviewID
            anchors.fill: parent
            model: theModel
            headerVisible : false
        }
    }
    

    }

    the symbol treeview is marked as erroneous in Creator.



  • Hi!
    I have the same problem. I did not find any solution.
    I think this is only Qt GUI error. Because my project is compiled and work correctly.



  • Hi,
    same problem here, at least on OSX don't know about Windows.
    I can confirm the application compiles fine, any way to fix Qt Creator ?
    Thx !


  • Moderators

    @tvdp You can only suppress them. Just add // @disable-check M300 before TreeView. The same can be done by right-click > TreeView > "Add a Comment to Suppress This Message"



  • @p3c0 Thanks for the tip: it doesn't fix the designer itself, but at least I can continue using the text editor without too much hassle...


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.