Message Boards Message Boards


set cursor in an InputField

Posted 5 years ago
2 Replies
0 Total Likes

n = 1;x = {Null}; Dynamic[Grid[ Table[With[{i = i}, {i, InputField[ Dynamic[x[[i]], (If[NumericQ[#], x[[i]] = #; AppendTo[x, Null]; n++]) &], ImageSize -> 50]}], {i, n}]]]

I'm trying to create a form to input lists. If you enter a value in the empty InputField, then appears a new InputField for the next value. Is it possible, that the cursor is automaically in this new InputField, so that you can start entering the new value without choosing the InutField with your mouse?

Greetings from Switzerland.

2 Replies

This answer and links from this topic should help you:

Posted 5 years ago

Thx for the link. My skills are not good enough yet to understand the solution there, but I will try it!

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
or Discard

Group Abstract Group Abstract