Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Error in declaration within accessors
Forum Updated to NodeBB v4.3 + New Features

Error in declaration within accessors

Scheduled Pinned Locked Moved Solved General and Desktop
8 Posts 3 Posters 811 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.
  • T Offline
    T Offline
    thippu
    wrote on last edited by
    #1

    Hi,
    error:
    AmpConfiguration::AmpConfiguration(QObject *) is private within this context amp_=new AmpConfiguration(this);
    decalared under the public itself but not working,
    link
    output

    If I do this error will disappear, I need help in understanding spaces between accessers.

    aha_1980A 1 Reply Last reply
    0
    • Christian EhrlicherC Offline
      Christian EhrlicherC Offline
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Because Q_OBJECT defines some private variables:
      https://code.woboq.org/qt5/qtbase/src/corelib/kernel/qobjectdefs.h.html#_M/Q_OBJECT

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      T 1 Reply Last reply
      2
      • T thippu

        Hi,
        error:
        AmpConfiguration::AmpConfiguration(QObject *) is private within this context amp_=new AmpConfiguration(this);
        decalared under the public itself but not working,
        link
        output

        If I do this error will disappear, I need help in understanding spaces between accessers.

        aha_1980A Offline
        aha_1980A Offline
        aha_1980
        Lifetime Qt Champion
        wrote on last edited by
        #3

        @thippu

        please provide code and compile errors as text, not as mobile screen photo.

        Qt has to stay free or it will die.

        T 1 Reply Last reply
        0
        • aha_1980A aha_1980

          @thippu

          please provide code and compile errors as text, not as mobile screen photo.

          T Offline
          T Offline
          thippu
          wrote on last edited by
          #4

          @aha_1980

          @aha_1980 said in Error in declaration within accessors:

          please provide code and compile errors as text, not as mobile screen photo.

          It was from an isolated server which does not connected to the internet, so could not able to copy and paste but will try to type and submit from now onwards

          aha_1980A 1 Reply Last reply
          0
          • T thippu

            @aha_1980

            @aha_1980 said in Error in declaration within accessors:

            please provide code and compile errors as text, not as mobile screen photo.

            It was from an isolated server which does not connected to the internet, so could not able to copy and paste but will try to type and submit from now onwards

            aha_1980A Offline
            aha_1980A Offline
            aha_1980
            Lifetime Qt Champion
            wrote on last edited by
            #5

            @thippu

            Thanks. The problem is, you get help here, but that will not help anyone later once the picture is no longer available.

            Also, I'm having a hard time reading this on my phone right now.

            Qt has to stay free or it will die.

            T 1 Reply Last reply
            0
            • Christian EhrlicherC Christian Ehrlicher

              Because Q_OBJECT defines some private variables:
              https://code.woboq.org/qt5/qtbase/src/corelib/kernel/qobjectdefs.h.html#_M/Q_OBJECT

              T Offline
              T Offline
              thippu
              wrote on last edited by
              #6

              @Christian-Ehrlicher said in Error in declaration within accessors:

              Because Q_OBJECT defines some private variables:
              https://code.woboq.org/qt5/qtbase/src/corelib/kernel/qobjectdefs.h.html#_M/Q_OBJECT

              I'm finding difficulty in understanding.
              provide me an example, please?

              1 Reply Last reply
              0
              • Christian EhrlicherC Offline
                Christian EhrlicherC Offline
                Christian Ehrlicher
                Lifetime Qt Champion
                wrote on last edited by
                #7

                When you take a look at the Q_OBJECT macro you'll see that it expands to some code which adds a private member section.

                Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                Visit the Qt Academy at https://academy.qt.io/catalog

                1 Reply Last reply
                1
                • aha_1980A aha_1980

                  @thippu

                  Thanks. The problem is, you get help here, but that will not help anyone later once the picture is no longer available.

                  Also, I'm having a hard time reading this on my phone right now.

                  T Offline
                  T Offline
                  thippu
                  wrote on last edited by
                  #8

                  @aha_1980 said in Error in declaration within accessors:

                  Thanks. The problem is, you get help here, but that will not help anyone later once the picture is no longer available.

                  Sorry:

                  Also, I'm having a hard time reading this on my phone right now.

                  I will type next onwards.

                  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