// This script is run when the textbox is clicked. i = 0; // Search for all textboxes and remove their focus and turn their // cursors off. while (i < instance_count) { // Look for textbox instances. if (get_parent(instance_id[i]) = objTextboxParent) { with (instance_id[i]) { focus = false; cursorOn = false; } } i += 1; } // Set focus for this textbox. focus = true; cursorOn = true; alarm[0] = cursorDelay; keyboard_string = myText;