Summary

team lib

In this chapter we've looked at how you use code in reports. This varies from just using functions in fields to using events and larger sections of code in the code module behind the report. Even at its very simplest, you can see that adding code to reports can make a difference.

The important things to consider are:

  • You can use expressions as the ControlSource of a field, just by placing an = sign in front of the expression.

  • You can use the Format event to allow you to change the layout of reports, such as making fields visible, or changing the formatting of a field.

  • You can use the Open and Close events to trigger other actions, such as loading a form.

You probably won't use much code in your reports, just limiting it to the samples shown here. Now that you've seen code behind both forms and reports, it's time to look at a little advanced programming.

 
team lib


Beginning Access 2002 VBA
Beginning Access 2002 VBA (Programmer to Programmer)
ISBN: 0764544020
EAN: 2147483647
Year: 2003
Pages: 256

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net