Results 1 to 3 of 3

Thread: How to load from other qml file?

  1. #1
    Join Date
    Jan 2016
    Posts
    13
    Thanks
    6
    Qt products
    Qt5
    Platforms
    Unix/X11

    Default How to load from other qml file?

    i have subfolder "subqmls", qml files in it

    Qt Code:
    1. // a.qml -- subqmls/a.qml
    2. import QtQuick 2.0
    3.  
    4. Text {
    5. id: text1
    6. text: qsTr("Text")
    7. }
    To copy to clipboard, switch view to plain text mode 

    Qt Code:
    1. //main.qml
    2. import QtQuick 2.3
    3. import QtQuick.Window 2.2
    4. import "subqmls"
    5. Window {
    6. visible: true
    7.  
    8.  
    9. Text {
    10. id: text1
    11. }
    12. }
    To copy to clipboard, switch view to plain text mode 
    not working

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: How to load from other qml file?

    What is not working? main.qml looks fine to me.
    Are you getting any error?

    Cheers,
    _

  3. The following user says thank you to anda_skoa for this useful post:

    umnbr (15th February 2016)

  4. #3
    Join Date
    Jan 2016
    Posts
    13
    Thanks
    6
    Qt products
    Qt5
    Platforms
    Unix/X11

    Default Re: How to load from other qml file?

    it worked by capitalized A.qml

Similar Threads

  1. How to load My own .cur file and set cursor
    By AKB48 in forum Qt Programming
    Replies: 2
    Last Post: 13th December 2016, 01:49
  2. Load CSV file into QTableWidget
    By thecml in forum Newbie
    Replies: 1
    Last Post: 24th May 2015, 17:06
  3. Load pls file with QMediaPlaylist
    By KeineAhnung in forum Newbie
    Replies: 1
    Last Post: 19th August 2014, 13:43
  4. Load from a file to QSqlTableModel
    By dd44 in forum Qt Programming
    Replies: 4
    Last Post: 28th August 2012, 17:02
  5. Load ActiveX from file
    By Passer_dj in forum Qt Programming
    Replies: 1
    Last Post: 14th August 2007, 00:24

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.