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. Connection between two Pages in SwipeView
Forum Updated to NodeBB v4.3 + New Features

Connection between two Pages in SwipeView

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
function createiste
3 Posts 2 Posters 310 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.
  • E Offline
    E Offline
    Egon Schaal
    wrote on last edited by
    #1

    main.qml
    ApplicationWindow {
    visible: true

    SwipeView {
        id: swipeViewId
        currentIndex: 0
    
        SettingsForm {
            onLoopFinished:
                ResultForm.createList()
        }
    
        ResultForm {
        }
    
    }
    

    SettingsForm.qml

    Page {
    id: settingsId
    padding: 10

    signal loopFinished
    

    }

    ResultForm.qml
    Page {
    id: listId

    function createList()
    {
    console.log("ResultForm")
    }

    My question is. How can I define a connection between Settingsform.qml and ResultForm.qml with signal loopFinished and slot createList in main.qml
    I've got Error
    qrc:/main.qml:21: TypeError: Property 'createList' of object [object Object] is not a function

    J.HilkJ 1 Reply Last reply
    0
    • E Egon Schaal

      main.qml
      ApplicationWindow {
      visible: true

      SwipeView {
          id: swipeViewId
          currentIndex: 0
      
          SettingsForm {
              onLoopFinished:
                  ResultForm.createList()
          }
      
          ResultForm {
          }
      
      }
      

      SettingsForm.qml

      Page {
      id: settingsId
      padding: 10

      signal loopFinished
      

      }

      ResultForm.qml
      Page {
      id: listId

      function createList()
      {
      console.log("ResultForm")
      }

      My question is. How can I define a connection between Settingsform.qml and ResultForm.qml with signal loopFinished and slot createList in main.qml
      I've got Error
      qrc:/main.qml:21: TypeError: Property 'createList' of object [object Object] is not a function

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

      @Egon-Schaal

      SettingsForm {
              onLoopFinished:
                  resultFormId.createList()
          }
      
          ResultForm {
       id: resultFormId
          }
      

      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.

      1 Reply Last reply
      1
      • E Offline
        E Offline
        Egon Schaal
        wrote on last edited by
        #3

        Thanks that works

        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