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. [SOLVED] How to get Object's pointer instantiated in QML engine
QtWS25 Last Chance

[SOLVED] How to get Object's pointer instantiated in QML engine

Scheduled Pinned Locked Moved Solved QML and Qt Quick
mvcquickengine
2 Posts 1 Posters 1.7k 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.
  • K Offline
    K Offline
    Kofr
    wrote on 18 Jul 2016, 10:21 last edited by Kofr
    #1

    I have
    qmlRegisterType<DataModel>("one.DataModel", 1, 0, "DataModel");

    and I instance this in QML
    DataModel { }

    I need to get pointer to the istantiated object in C++ side. BUT I do not want to use aproach with use of findChild().
    How to get a pointer?

    1 Reply Last reply
    0
    • K Offline
      K Offline
      Kofr
      wrote on 18 Jul 2016, 10:57 last edited by
      #2

      http://www.qtcentre.org/threads/66403-How-to-get-Object-s-pointer-instantiated-in-QML-engine?p=291959#post291959

      1 Reply Last reply
      0

      1/2

      18 Jul 2016, 10:21

      • 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