Access.2007.VBA.Bibl..

(John Hannent) #1
If Err.Number = 429 Then
Set appExcel = CreateObject(“Excel.Application”)
Resume Next
Else
MsgBox “Error No: “ & Err.Number & “; Description: “ _
& Err.Description
Resume ErrorHandlerExit
End If

End Sub

A finished worksheet is shown in Figure 3.13.

FIGURE 3.13

A worksheet filled with data and formatted using VBA code.


Summary ............................................................................................................................


When you need to export Access data to Excel worksheets so that everyone who has Office can
work with them, you can use the techniques discussed in this chapter to export Access data in the
interface, or using VBA code, either to a plain default worksheet, or a formatted worksheet created
from an Excel template.

Analyzing Data with Excel 3

Free download pdf