1.61 Osk .502 1.61.1 Osk.Close .502 1.61.2 Osk.GetText .503 1.61.3 Osk.lsAvailable .503 1.61.4 Osk.Open .504 Osk Osk.Close Brief Closes the OSK opened by this script. Definition j Osk.Close () Arguments None Return Values None Description Closes the OSK opened by this script. If the OSK was not opened by this script, then this function has no effect. Examples j Osk.Close() See Also • Osk.Open Osk.GetText Brief Obtain the text the user entered in the OSK. Definition j string Osk.GetText() Arguments None Return Values The text that was entered by the user or nil if the user cancelled input or not in the callback context. Description Returns the text that was entered by the user in the OSK. Only valid during the registered callback for the OSK request that triggered the call. Examples j mytext = Keyboard.GetText() See Also None Osk.lsAvailable Brief Checks if it is possible to to open the OSK. Definition boolean Osk.IsAvailable() Arguments None Return Values true if the script is able to open the OSK, false if the OSK is unavailable. Description Checks if it is possible to to open the OSK. Examples if Osk.IsAvailable() == true then Osk.Open( "OnText()", "How old are you?", "", 3, false, true, false ) | end See Also None Osk.Open Brief Opens the OSK to request a string from the user. Definition boolean Osk.Open( function callback, string title, string initialText, number maxCharacters, CharacterSet characterSet, boolean allowReturn ) Arguments callback - The Lua function to execute when the OSK has a result. Max 127 characters.title - The title to give the OSK. Max 127 characters.initialText - The initial text to add to the OSK. Max 511 characters.maxCharacters - The maximum number of characters (not bytes) to request from the user. Max 511 characters.characterSet - A valid character set enum value (see details)allowReturn - Set to true to allow the user to enter new line characters. Return Values false if the OSK could not be started at this time. Description Opens up an instance of the OSK to accept text input from the user. Only one instance of the OSK can be open at a time. characterSet can be any of the following: • CharacterSet.Default • CharacterSet. LatinOnly • CharacterSet. NumericalOnly • CharacterSet. Password Examples ! success = Osk.Open( OnNumerical, "What is your pin?", "0000", 4, CharacterSet.NumericalOnly, false ) See Also None