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. QAxObject SIGSEGV
Forum Update on Tuesday, May 27th 2025

QAxObject SIGSEGV

Scheduled Pinned Locked Moved General and Desktop
11 Posts 2 Posters 4.8k Views 1 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.
  • M Offline
    M Offline
    Maxbester
    wrote on 7 May 2013, 11:19 last edited by
    #1

    Hi there,

    I am developing an application using an existing tlb file. I use dumpcpp to generate a C++ namespace.

    But when I try to access some members, a segmentation fault occurs in qmetaobject.cpp line 679.

    This is in: @int QMetaObject::indexOfProperty(const char *name) const;@

    I guess it means that Qt can't find this member in the object. However I am sure it exists. What could be wrong?

    Should I use querySubObject() instead of calling directly the generated method?

    1 Reply Last reply
    0
    • M Offline
      M Offline
      Maxbester
      wrote on 8 Nov 2013, 15:37 last edited by
      #2

      Still no reply and still no solution.

      I realised the problem occurs when I try to access a method when the ActiveX connection is not established yet.

      1 Reply Last reply
      0
      • S Offline
        S Offline
        SGaist
        Lifetime Qt Champion
        wrote on 8 Nov 2013, 17:22 last edited by
        #3

        Hi,

        I'm not a QAx specialist, but are you sure your object is valid when you try to call that method ?

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        0
        • M Offline
          M Offline
          Maxbester
          wrote on 8 Nov 2013, 18:08 last edited by
          #4

          Absolutely not. That's the point. The object is sometimes valid but not always and I don't know how to check it...

          1 Reply Last reply
          0
          • S Offline
            S Offline
            SGaist
            Lifetime Qt Champion
            wrote on 8 Nov 2013, 21:29 last edited by
            #5

            Can you show how you create it and use it ?

            Interested in AI ? www.idiap.ch
            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            0
            • M Offline
              M Offline
              Maxbester
              wrote on 14 Nov 2013, 12:16 last edited by
              #6

              I use a tlb file. My .pro file has:

              @TYPELIBS = $$system( dumpcpp lib/Pulse.tlb -n PulseLabShop -o src/controller/Pulse )@

              Then I create the connection with:

              @PulseLabShop::Application *app = new PulseLabShop::Application();@

              In a destructor I have:

              @
              app->CloseProject(true);
              app->Quit();
              @

              But if the connection has been lost I have a SIGSEGV error. I would like to check if I can reliably call the Quit() function.

              1 Reply Last reply
              0
              • S Offline
                S Offline
                SGaist
                Lifetime Qt Champion
                wrote on 14 Nov 2013, 21:03 last edited by
                #7

                What other methods are available in this Application object ?

                Interested in AI ? www.idiap.ch
                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                0
                • M Offline
                  M Offline
                  Maxbester
                  wrote on 16 Nov 2013, 12:13 last edited by
                  #8

                  It has many but all will fail if the connection has not been set or if the connection is broken. I think the QMetaObject class shall have a method that tests the establishment of a connection.

                  Hasn't anyone faced this problem before?

                  1 Reply Last reply
                  0
                  • S Offline
                    S Offline
                    SGaist
                    Lifetime Qt Champion
                    wrote on 16 Nov 2013, 21:20 last edited by
                    #9

                    That's a question you should ask on the interest mailing list, you'll find Qt's developers/maintainers there (this forum is more user oriented)

                    Interested in AI ? www.idiap.ch
                    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                    1 Reply Last reply
                    0
                    • M Offline
                      M Offline
                      Maxbester
                      wrote on 18 Nov 2013, 11:02 last edited by
                      #10

                      Okay you're right.

                      Just an additional information.

                      I voluntarily generated an error while connecting to the QAxObject and I got those messages in the Qt Creator console:

                      @
                      CoCreateInstance failure (The class has not a valid license.)

                      QAxBase::setControl: requested control {587b4a33-81d3-11cf-91c5-0020af429815} could not be instantiated

                      QAxBase::qt_metacall: Object is not initialized, or initialization failed
                      @

                      So some messages are emitted. The question is how to catch them...

                      1 Reply Last reply
                      0
                      • S Offline
                        S Offline
                        SGaist
                        Lifetime Qt Champion
                        wrote on 18 Nov 2013, 21:28 last edited by
                        #11

                        Maybe the QAxBase::exception signal ?

                        Interested in AI ? www.idiap.ch
                        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                        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