Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Learning
  3. Qt in Education
  4. I need help!!!
QtWS25 Last Chance

I need help!!!

Scheduled Pinned Locked Moved Unsolved Qt in Education
6 Posts 5 Posters 624 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.
  • A Offline
    A Offline
    AliatorC
    wrote on last edited by
    #1

    Help Needed: Implementing Files in Qt Creator Project
    Hello everyone,
    I am having trouble integrating my files into my Qt Creator project. I am relatively new to working with Qt and would greatly appreciate your support.
    My Problem:
    I am unable to successfully add my existing files to my project.
    The files do not appear in the project structure even though I have tried to add them.
    What I Have Tried:
    Right-clicking on the project and selecting "Add Existing Files..."
    Manually editing the .pro file
    Restarting Qt Creator
    Questions:
    Is there a specific process I should follow to correctly add files to my project?
    Do I need to make any additional configurations for the files to be recognized?
    Are there common mistakes that beginners make during this process?
    I would be grateful for any tips or advice. Please let me know if you need any further information.
    Thank you in advance for your help!

    Add me on Discord aliatorc

    1 Reply Last reply
    0
    • artwawA Offline
      artwawA Offline
      artwaw
      wrote on last edited by
      #2

      Manually added entries should be under appropriate list, one of sources +=, headers += or disfiles += .

      Please see https://doc.qt.io/qt-6/qmake-project-files.html and https://doc.qt.io/qt-6/qmake-variable-reference.html

      For more information please re-read.

      Kind Regards,
      Artur

      1 Reply Last reply
      0
      • S Offline
        S Offline
        SimonSchroeder
        wrote on last edited by
        #3

        First of all, the steps you have taken seem to be plausible. This is how it should usually work.

        If you don't have existing Qt projects, you should rather use CMake instead of .pro files. This is going to be the future.

        J.HilkJ 1 Reply Last reply
        0
        • S SimonSchroeder

          First of all, the steps you have taken seem to be plausible. This is how it should usually work.

          If you don't have existing Qt projects, you should rather use CMake instead of .pro files. This is going to be the future.

          J.HilkJ Offline
          J.HilkJ Offline
          J.Hilk
          Moderators
          wrote on last edited by J.Hilk
          #4

          @SimonSchroeder does QtC now support adding existing files via gui, in a cmake project ofc ? Last time I checked you would have to type it all out by hand in the cmake file


          Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


          Q: What's that?
          A: It's blue light.
          Q: What does it do?
          A: It turns blue.

          artwawA 1 Reply Last reply
          0
          • J.HilkJ J.Hilk

            @SimonSchroeder does QtC now support adding existing files via gui, in a cmake project ofc ? Last time I checked you would have to type it all out by hand in the cmake file

            artwawA Offline
            artwawA Offline
            artwaw
            wrote on last edited by
            #5

            @J-Hilk it does, I just tested.

            For more information please re-read.

            Kind Regards,
            Artur

            1 Reply Last reply
            3
            • N Offline
              N Offline
              Neha Kakar
              wrote on last edited by
              #6
              This post is deleted!
              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