[SOLVED] Problem Using Directory Import for QML Files
I searched the forums and doc, and can't figure this one out...
I'm using Qt Creator 3.1.81 based on Qt 5.2.2 (Mac) with QtQuick 2.1
I'm trying to use a user-defined object type:
(aside: the qml file I'm attempting to import is in the same directory and my main.qml, and yet I have to supply the above import statement. I couldn't just say <code>import "."</code>)
My directory structure looks like this:
<code>WPResources.qrc</code> has this in it:
<code>main.qml</code> has this import statement (which seems to be OK since it gives no error);
But when I try to use the type <code>choosePlates</code> like this, in <code>main.qml</code>:
I get the error: @qrc:/qml/WeightPlateQtQ/main.qml:88:5: Cannot assign to non-existent property "choosePlates" @
<code>choosePlates.qml</code> just looks like this right now:
@import QtQuick 2.1
import QtQuick.Controls 1.0
This looks like it should be really really simple, so I figure I'm just doing something really really naive (or maybe stupid, you never know.)
Can anyone provide enlightenment?
I'm pretty sure that the convention is to use a capital letter for element names, so it's nto as simple as renaming choosePlates.qml to ChoosePlates.qml is it?
In addition, if the files are in the same directory, I'm not sure you even need the import statement.
That did it!
So... id properties have to start with lowercase (that I read somewhere), but component names have to start with upper case? That I didn't see anywhere.