Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Enable or disable Next button on qt installer framework.
Qt 6.11 is out! See what's new in the release blog

Enable or disable Next button on qt installer framework.

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
1 Posts 1 Posters 284 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.
  • N Offline
    N Offline
    Nguyen Thang Phong
    wrote on last edited by
    #1

    I using QT Installer Framework version 4.8.
    I tried enable Next button with the code below:

                var loginObj = widget.findChild("btnLogin");
                var usernameObj = widget.findChild("txtUsername");
                var passwordObj = widget.findChild("txtPassword");
    
                if (loginObj != null) {
                    loginObj.clicked.connect(() => {
                        var username = usernameObj.text;
                        var password = passwordObj.text;
    
                        if (username != null && password != null) {
                            var hashValue = mymodule.hashPassword(password);
                            
                            if (mymodule.verifyAccount(username, hashValue) == true) {
                                var isOk = QMessageBox.information("", "Success", "Login successful !", QMessageBox.Ok);
                                
                                if (isOk == QMessageBox.Ok) {
                                    widget.complete = true;
                                }
                            } else {
                                QMessageBox.critical("", "Error", "Invalid username or password !");
                            }
                        }
                    });
                }
    

    I debug and display widget.complete have set to true but Next button is not enabled.
    Help me the solution.

    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