I believe the way to jump fields is by setting the keyboard focus with setKeyboardFocus(). Here is one way to do that.
[code]
– set up a handler for text boxes
function thandler(event)
– user hits enter, handle the text however you like
if event.phase == “submitted” then
something.something
– this phase hits after each new letter is typed
elseif event.phase == “editing” then
– now lets check length of text, if greater than 12
if string.len(event.text) > 12 then
– text is > 12 so lets bump to the next text field
local tid = event.target.id + 1
if tid < 4 then
– we bump by setting the keyboard focus
setKeyboardFocus(tbox[tid])
end
end
end
end
tbox = {}
tbox[1] = display.newTextField(50, 150, 220, 36, thandler)
tbox[1].id = 1
tbox[2] = display.newTextField(150, 250, 220, 36, thandler)
tbox[2].id = 2
tbox[3] = display.newTextField(250, 350, 220, 36, thandler)
tbox[3].id = 3
[/code] [import]uid: 56820 topic_id: 24653 reply_id: 99880[/import]