Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Password authentication using two different qml files

Password authentication using two different qml files

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
4 Posts 4 Posters 671 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.
  • J Offline
    J Offline
    JasmineSethi
    wrote on last edited by JasmineSethi
    #1

    As i am implementing this for mobile application so m posting this question here.

    I have one qml file as firstscreen.qml and another as secondscreen.qml.
    I have created two text field shown as below:

    firstcsreen.qml(for password to enter)
    TextField
    {
    id: frst_pwdTextfield
    width: 100
    height: 100
    echoMode: TextInput.Password
    }
    TextField
    {
    id: scnd_pwdTextfield
    width: 100
    height: 100
    echoMode: TextInput.Password
    }

    secondscreen.qml (for password to re-enter)
    TextField
    {
    id: frst_pwdTextfield1
    width: 100
    height: 100
    echoMode: TextInput.Password
    }
    TextField
    {
    id: scnd_pwdTextfield1
    width: 100
    height: 100
    echoMode: TextInput.Password
    }
    When i enter password in the 1st screen and re-enter the password in the second screen , it should match and i want to confirm whether it is same or not (without storing the password in any database).
    In other words, how can i compare inputs entered in first screen with the inputs entered in the second screen?
    How this can be implemented?

    1 Reply Last reply
    0
    • S Offline
      S Offline
      shaan7
      wrote on last edited by
      #2

      You can put both the UIs in different pages of a SwipeView.

      1 Reply Last reply
      0
      • Y Offline
        Y Offline
        Yaswanth
        wrote on last edited by
        #3

        In main.qml create a property to store the password temporarily and use it in the second qml. (As it is with in the application level it is secured). After your task is done clear the property in main.qml.

        1 Reply Last reply
        0
        • dheerendraD Offline
          dheerendraD Offline
          dheerendra
          Qt Champions 2022
          wrote on last edited by
          #4

          First you should not have two different qml files for this task. Just create one QML file called LoginCheck.qml

          You create two objects of this LoginCheck.qml. Show one object at a time. Move from object to other object based on the user action. Set the properties of second object(SecondScreen) when moving from first object(first screen)

          Dheerendra
          @Community Service
          Certified Qt Specialist
          http://www.pthinks.com

          1 Reply Last reply
          1

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved