// Only if the textbox has focus and was not tabbed to during this // step, it can receive a new tab. if ((not focus) or tabbed) { exit; } // Init some variables. thisInstanceFound = false; thisInstance = 0; i = 0; // Search through all instances to find where in the instance list // this instance is placed. while (( i < instance_count) and (not thisInstanceFound)) { // Look for this object if (instance_id[i] = id) { thisInstanceFound = true; thisInstance = i; } i += 1; } nextInstanceFound = false; nextInstance = thisInstance; nextBoxID = instance_id[thisInstance]; // Search for next textbox instance that has the object "objTextboxParent" as parent. while (( i != thisInstance) and (not nextInstanceFound)) { tempID = instance_id[i]; if (get_parent(tempID) = objTextboxParent) { nextInstanceFound = true; nextInstance = i; nextBoxID = tempID; } i = (i + 1) mod instance_count; } // Set this focus to false. focus = false; cursorOn = false; // Set focus to the next textbox. io_clear(); with (nextBoxID) { keyboard_string = myText; focus = true; alarm[0] = cursorDelay; cursorOn = true; tabbed = true; }