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. is there equivalent statement goto in QML or new idea for refactoring it?
Forum Updated to NodeBB v4.3 + New Features

is there equivalent statement goto in QML or new idea for refactoring it?

Scheduled Pinned Locked Moved Solved QML and Qt Quick
3 Posts 2 Posters 1.1k 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.
  • stackprogramerS Offline
    stackprogramerS Offline
    stackprogramer
    wrote on last edited by stackprogramer
    #1

    i need a statement when i call it,the processor program from javascript source function , goes to special line like 9 in a qml file that i want to it.
    or in otherwords my question is :
    is there a statement like goto (in c++), in qml?

    1 Reply Last reply
    0
    • I Offline
      I Offline
      iter
      wrote on last edited by
      #2

      QML uses JavaScript, there is no goto in JS, so no.

      If you post some code with what you try to illustrate, there is likely a proper way to do it without goto.

      1 Reply Last reply
      0
      • stackprogramerS Offline
        stackprogramerS Offline
        stackprogramer
        wrote on last edited by stackprogramer
        #3

        last night my problem is solved.i need goto in my code.
        finally i define a function in that line,and i call it,i.e. the function can same goto for programmer.

        function sample()
        {
        
        
        }
        
        ....
        
        sample();
        

        thanks for attention.

        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