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. QLineEdit Array Question
Forum Updated to NodeBB v4.3 + New Features

QLineEdit Array Question

Scheduled Pinned Locked Moved General and Desktop
5 Posts 3 Posters 2.0k Views 2 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.
  • w00t1234W Offline
    w00t1234W Offline
    w00t1234
    wrote on last edited by
    #1

    Hi Guys I Have A Question. How Do I Use QLineEdit Array
    Ex: ui->QLineArray.name->text[0] ?

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      Rather

      myLineEditArray[0]->text();
      

      to adapt to your situation

      Hope it helps

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • w00t1234W Offline
        w00t1234W Offline
        w00t1234
        wrote on last edited by w00t1234
        #3

        Thanks For Your Reply But It's Not Working :(

        My İf-Else Block
        if(ui->MyQLineEdit[0].text() == 0)
        .....
        else
        ......

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          How did you build your array ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • A Offline
            A Offline
            alex_malyu
            wrote on last edited by
            #5

            Show declaration.
            Since it was generated from ui, this is probably not an array, but pointer to QLineEdit instance.
            If you gave your QLineEdit name 'name',

            Your would be checking number of symbols :

            ui->name().text().count() or ui.name().text().count() depending on the way you store ui (instance or pointer)

            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