When running the following in a notebook (not a deployed CDF
file), it can sometimes be annoying that accidentally pressing Shift-Return breaks out of the user interface:
Panel@DynamicModule[{input = ""}, InputField[Dynamic[input], String]]
I would like to know if one can (programmatically) prevent such a cell from being "evaluated" when Shift-Return is pressed, so that the user stays in the InputField
instead of being thrown out of it while seeing a new generated cell appear.
InputField
is, and make it returnNull
at the end. You can test by setting it to a simpleCellEvaluationFunction->(Null& )
. $\endgroup$