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. [SOLVED]How to set the default button of a MessageDialog in QML?
QtWS25 Last Chance

[SOLVED]How to set the default button of a MessageDialog in QML?

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 1.0k 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.
  • C Offline
    C Offline
    CoderJeff
    wrote on last edited by CoderJeff
    #1

    The default button is "Yes", but I want to set the button "No" as the default button.

    How to do it?

    p3c0P 1 Reply Last reply
    0
    • C CoderJeff

      The default button is "Yes", but I want to set the button "No" as the default button.

      How to do it?

      p3c0P Offline
      p3c0P Offline
      p3c0
      Moderators
      wrote on last edited by
      #2

      Hi @CoderJeff,
      I guess currently there's no way to do so in QML. You can create your own Dialog, add Buttons to it and set focus to the required one.

      157

      C 1 Reply Last reply
      0
      • p3c0P p3c0

        Hi @CoderJeff,
        I guess currently there's no way to do so in QML. You can create your own Dialog, add Buttons to it and set focus to the required one.

        C Offline
        C Offline
        CoderJeff
        wrote on last edited by
        #3

        Hi @p3c0,

        Thank you stop me looking for the solution in time. I have spent so much time on this problem.

        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