Results 1 to 4 of 4

Thread: Need qml component to get ip address from user

  1. #1
    Join Date
    Apr 2014
    Posts
    125
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Android Maemo/MeeGo

    Question Need qml component to get ip address from user

    Hello

    The user of my qml app needs to enter an ip address;

    I'm looking for a qml editbox (or text input,...) with
    the dot already included and ip address validation.

    Any ideas?

    Thanks

    Mut.

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Need qml component to get ip address from user

    You could use a TextInput or TextField with a RegExpValidator to restrict the general pattern, and then valdiate the values inside the pattern.

    Cheers,
    _

  3. #3
    Join Date
    Apr 2014
    Posts
    125
    Qt products
    Qt5 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Android Maemo/MeeGo

    Default Re: Need qml component to get ip address from user

    Thanks for the reply.
    Could you be more precise. Any example code that you know?

  4. #4
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Need qml component to get ip address from user

    There is an example for using an IntValidator right there in the documentation of TextInput's validator property.

    A Google query for "qml textinput validator" returns this as its first hit.

    Cheers,
    _

Similar Threads

  1. Using Qt.component() in c++?
    By mut in forum Qt Quick
    Replies: 1
    Last Post: 29th March 2016, 21:30
  2. help me create login page with multi-user (admin-user)
    By phovyanz in forum Qt Programming
    Replies: 2
    Last Post: 22nd February 2016, 08:57
  3. 64 bit COM component
    By hamidarr in forum Qt Programming
    Replies: 6
    Last Post: 16th November 2014, 10:31
  4. Replies: 2
    Last Post: 27th November 2008, 10:16
  5. Is there an Led component for qt ?
    By lovelypp in forum Qt Programming
    Replies: 2
    Last Post: 10th July 2008, 17:36

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.