Sign in to follow this  
Followers 0
Paulie

Continuing Input Box

3 posts in this topic

#1 ·  Posted (edited)

If i made 4-5 input boxes, how can i make it so that when one was at its character limit, it would automatically jump to the next one, like when you enter serial numbers?

So they don't have to physically click to give focus to the next input?

Heres a GUI i made to save people from having to get their feet too wet:

#include <GUIConstants.au3>

$GUI = GUICreate("Input Box Test", 485, 77, 341, 427)
GUISetBkColor(0xDDDDDD)
$Label1 = GUICtrlCreateLabel("Input some numbers and letters", 16, 8, 151, 17)
GUICtrlSetBkColor(-1, 0xDDDDDD)
$Input1 = GUICtrlCreateInput("", 20, 40, 80, 20)
GUICtrlSetLimit($Input1, 5)
$Input2 = GUICtrlCreateInput("", 120, 40, 80, 20)
GUICtrlSetLimit($Input2, 5)
$Input3 = GUICtrlCreateInput("", 220, 40, 80, 20)
GUICtrlSetLimit($Input3, 5)
$Input4 = GUICtrlCreateInput("", 320, 40, 80, 20)
GUICtrlSetLimit($Input4, 5)
GUISetState()


While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

    EndSwitch
WEnd
Edited by Paulie

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Perhaps have it check for the amounts of characters in one and once that one's reached it's maximum number have it default to the next input.

$GUI_SS_DEFAULT_EDIT, $GUI_SS_DEFAULT_INPUT perhaps?

Edited by BALA

[font="Comic Sans MS"]BA-LA[/font]http://ba-la.110mb.comJoin my community, CLICK HEREAlternative links to my site:http://www.ba-la.tkhttp://www.ba-la.co.nrContact me if you would like to help with some of my projects: joeythepirate@gmail.com

Share this post


Link to post
Share on other sites

Just found "ControlFocus()" in the helpfile... seems to do what i want

I'll test it, but thanks for the help

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0