Within forms I would like to add a script to check the contents of a textfield (TextBox1), to determine if it has been left empty. If it is empty do nothing and wait (or flash to prompt the user). If populated with alphanumeric text length greater than > 5 characters then make visible a dropdown box, dropdown2 for example and stop any user prompt. I presume I would add the script under the 'run custom validation script' of validate option of properties box for which the checking is required, TextBox1 in this example case.
I would re-think this approach. Imagine the user enters a value that's longer than 5 characters, but then realizes they made a mistake and want to change it. They wouldn't be able to do that if you make that field non-editable...
Sorry but I don't understand why they would not be able to edit the text freely. If the text character length was less than 5 chars then Dropdown2 would simply return to a hidden state. I essentially want to ensure the data field is populated before they proceed to the next step.
If populated with alphanumeric text length greater than > 5 characters then make visible a dropdown box, dropdown2 for example and stop any user prompt.
Which field did you refer to in the last part of that sentence?
Sorry I wrote the reply in haste.
I am constructing a sequential assesment sheet. The user answers the first question using Dropdown1. Dropdown1 is always visible and it has four fields "Yes", "No", "Not Applicable" and " ". The inital value of the dropdown is " ". If the User selects "Not applicable" or "Yes" The dropdown associated with line two of the assesment becomes visible (Dropdown2). However if and only if the user selects "No" I would like to understand the reason and so I make a Text Field visible (TextBox1, for example). What I would like to do is check to ensure they have provided the additional information. Contextually I canot assess their answer, it could be random letters, but I do want to make sure some intentional alphnumeric content has been added. Unless that is, it can be determined if the spell check has detected any faults which would at least indicate a string of recongnisable words. However, when more than 5 characters, for example, have been entered I would like for the dropdown assocated with the second question (Dropdown2) to be made visible. So on and so on for the duration of the spreadsheet.
The reference to user prompts.
In my second reply post Textbox1, the field for additional entry when the user selects a "No" response from the corresponding dropdown Dropdown1.
Sorry I missed this element out of my more detailed response.
Bear in mind thgat there isn't any "wait" or "next step" in form filling. Users can and do fill fields in any order, rather than any order that suits you. So you have to be prepared for field validations and calculations to happen in any, random, order.
Given this the idea of "left empty" isn't really a thing as you can't tell a field that was ignored from a field that is not yet filled. If, however, you have a submit button, this is the time to check for anything the user missed out and report.