Microsoft Office Tutorials and References
In Depth Information
Making controls change other controls
Making controls change other controls
Controls on a form have an After Update event that occurs after
a successful Before Update event. If the Before Update event
cancels the data change because it fails validation (as previously
described), the After Update event will not fire. The After Update
event is used to take action following a successful change to
data, and one possible implementation is in changing how other
controls can be used following a change in the data.
In addition to each control having an After Update event, the
form also has an After Update event, after changes have been
successfully validated for the record, which you can use to take
further action based on values in several controls.
Change other controls
1 In Design view, locate a control to which you want to add an After
Update action, and click the Event tab in the Property Sheet pane.
In our example, we took the form from the previous task (“Validate
data entered in a control” on page 226) and added an additional
unbound text box (which has the Enabled property set to false).
2 Click the build button for the After Update event, and select Macro
(continued on the next page)
TIP In the macro designer, if you have a trusted database and
you want to use macro commands restricted to a Trusted
Document, remember to click Show All Actions. Otherwise, you will not
see the extended list of all available macro commands in the
dropdown list.
Search JabSto ::

Custom Search