Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Test available module
QtWS25 Last Chance

Test available module

Scheduled Pinned Locked Moved QML and Qt Quick
testavailablemodule
2 Posts 2 Posters 1.1k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    CharlieG
    wrote on 9 Oct 2015, 05:21 last edited by
    #1

    Hello,

    Is it possible to try import in QML document ?
    By example :

    try {
       import QtQuick 2.5
    }
    catch {
       import QtQuick 2.0
    }
    

    or use another instruction to test if a module is available

    Thank you in advance

    P 1 Reply Last reply 9 Oct 2015, 12:03
    0
  • P Offline
    P Offline
    p3c0 Moderators
    replied to CharlieG on 9 Oct 2015, 12:03 last edited by
    #2

    Hi @CharlieG
    AFAIK that is not possible from QML. But you can try checking for errors by loading the QML from C++ side. For eg. if you use QQmlComponent you can check for errors using errors.

    157

    1 Reply Last reply
    0

1/2

9 Oct 2015, 05:21

1 unread
  • Login

  • Login or register to search.
1 out of 2
  • First post
    1/2
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved