Refreshing values on a field change in Lotus Notes 7.0.2.
Posted on 2007-10-05
I am creating a form for a user registration database. The user has to answer some questions on the type of user that is being registered that determines what fields are displayed. I do not want to show these fields to the user until the questions are answered. That way, the user cannot start filling items out until the registration type is fully determined.
These questions are a group of ComboBox's. On the last box, I have the following code in the OnChange event.
Sub Onchange(Source As Field)
Dim ws As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Set uidoc = ws.CurrentDocument
If uidoc.FieldGetText("Exempt") <> "" Then Call uidoc.FieldSetText("ShowInfo","1" ) Else Call uidoc.FieldSetText("ShowInfo","0" )
On this field, I have selected the option "Refresh Values On Keyword Change" selected and on the form, I selected "Automatically Refresh Fields" selected. The problem is that the event does not kick off, until I exit the field, even if I make a change.
Any ideas how to initiate this without exiting the field? The only one I can come up with is to have a button labeled "Continue" that forces the fields to refresh and checks to see if all screening questions are complete. If they are, then it makes the rest of the form visible.
Any help would be appreciated.