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. Adding QML file (Qt Quick 2) to Qt project
Forum Updated to NodeBB v4.3 + New Features

Adding QML file (Qt Quick 2) to Qt project

Scheduled Pinned Locked Moved Solved QML and Qt Quick
6 Posts 2 Posters 1.8k Views 2 Watching
  • 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.
  • G Offline
    G Offline
    gabor53
    wrote on last edited by gabor53
    #1

    Hi,
    To implement qml busy indicator, I added Busy.qml to the project using File-New File or Project-QML File (Qt Quick 2). When I try to build it it gives me the following error message:
    :-1: error: No rule to make target 's', needed by 'debug/s.o'. Stop.
    What am I missing?

    I have a separate working qml project with the busy indicator,. Any way I can just import it into my Qt project? Thank you for your help.

    1 Reply Last reply
    0
    • sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      What is that "s" object - some c++ class or something? Does you Qt project have any QML there already or rather it is widget-based maybe?

      (Z(:^

      G 1 Reply Last reply
      0
      • sierdzioS sierdzio

        What is that "s" object - some c++ class or something? Does you Qt project have any QML there already or rather it is widget-based maybe?

        G Offline
        G Offline
        gabor53
        wrote on last edited by
        #3

        @sierdzio
        Hi,
        's' is not a class for sure. The truth is I have no idea what it is. The app is mostly widget based. This is the first QML file added (and my first try combining QML and Qt). So I appreciate any help.

        1 Reply Last reply
        0
        • sierdzioS Offline
          sierdzioS Offline
          sierdzio
          Moderators
          wrote on last edited by
          #4

          In order to embed QML components in QtWidgets you need to use QQuickWidget (well, there are other options, too).

          You need to check what "s" is. It is not QML component for sure, because the error you are getting comes from the Makefile and is related to c++. Check your .pro file, maybe there is some "s" there.

          (Z(:^

          G 1 Reply Last reply
          1
          • sierdzioS sierdzio

            In order to embed QML components in QtWidgets you need to use QQuickWidget (well, there are other options, too).

            You need to check what "s" is. It is not QML component for sure, because the error you are getting comes from the Makefile and is related to c++. Check your .pro file, maybe there is some "s" there.

            G Offline
            G Offline
            gabor53
            wrote on last edited by
            #5

            @sierdzio
            I still have no idea what 's' is, but after re-implementing busy.qml 's' disappeared and it works fine without any error. Thank you for your help.

            1 Reply Last reply
            1
            • sierdzioS Offline
              sierdzioS Offline
              sierdzio
              Moderators
              wrote on last edited by
              #6

              well, ok, good that it works now :) Happy coding!

              (Z(:^

              1 Reply Last reply
              0

              • Login

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