This question is limited to requesting a functional outline for a Central Validation Handler. The functionality needs to seperated into defined steps so that subsequent questions will be limited in scope.
I am having limited succses developing a class module that handles form validation and business logic control. I need to intercept form and form-control Before_Update events for Combo, List & Text box controls and prevent users from entering invalid data. I also need to intercept After_Update events to make sure data is enter into fields in the correct order and prevent users from skipping over combo and/or list box controls to avoid subsequent ListSource queries from failing.
Scenario: Forms with cascading text controls where subsequent ListSource queries are dependent on previous selections. All business logic is maintained in tables but ListSource queries will return empty s if any required selections are skipped.
ListSource for Combo-2 depends on the selection made in Combo-1
ListSource for Combo-3 depends on the selections made in Combo-1 & Combo-2
ListSource for Combo-4 depends on the selections made in Combo-1, Combo-2 & Combo-3
If a user skips forward from Combo-2 to Combo-4 without making a selection in the preceding Combo Boxes, the ListSource query associated with Combo-4 will return empty. This requires subsequent Combo Boxes to be disabled until all preceding Combo selections are made.
If a user were to go back and change a previously entered combo selection then all previously entered combo boxes from that point forward would have to be cleared automatically. The user would have to make new selections going forward from the place where the change occurred.
Example: A user has made selections in Combo-1 thru Combo- 8 and then goes back and changes combo 3 then Combo 4 thru 8 would be cleared programmatically; Combo 4 would be enabled and Combo 5 thru 8 would be disabled.
The code need to allow for records to be deleted, cancellation of unsaved changes made to existing records and cancellation creation of an uncompleted new record
I have been able to get the Input Validation and Business Logic control functionality working procedures separately but have been unable to combine the processes to work collectively.
The validation code I am using is a modified Class module downloaded from http://www.peterssoftware.com/fv.htm
. The class is only a conceptual example and is not fully functional as written. The business logic control functionality was written from scratch.
I will upload a zip-file to www.ee-stuff.com
that better illustrates the needed functionality. The zip file will include both a Visio document and JPG version of the diagram. Some functional details are incomplete and I realize that the concept may have to be completely reworked. Again, all I am seeking at this point is to establish a comprehensive functional roadmap.