Access.2007.VBA.Bibl..
Adjust worksheet print setup and margins: .PageSetup.PrintTitleRows = “$5:$5” .PageSetup.LeftFooter = “&F” .PageSetup.Center ...
Because the workbook was created in an older format, you will see “(Compatibility Mode)” in its title bar. The procedure starts ...
As a quick way to find out the syntax for various Excel commands, open an Excel work- sheet, turn on the macro recorder, perform ...
FIGURE 7.9 An Access form for entering timesheet data for export to Excel. FIGURE 7.10 A combo box list showing timesheets for e ...
FIGURE 7.11 Date information automatically filled in after selecting an employee. The CurrentWeekEndingand FillDateControlsproce ...
Private Sub FillDateControls() On Error GoTo ErrorHandler Dim strFormattedDate As String Fill week ending and weekday controls w ...
FIGURE 7.12 Selecting a client and project for a timesheet. If you need to modify the data on an existing timesheet, you can do ...
In the form footer there are three command buttons: the first (“Clear This Timesheet”) clears the timesheet so you can start ove ...
MsgBox prompt:=strPrompt, Buttons:=vbExclamation _ + vbOKOnly, Title:=strTitle Me![cboEmployeeID].SetFocus GoTo ErrorHandlerExit ...
DoCmd.RunCommand acCmdDeleteRecord Me![cboEmployeeID].Requery Me![cboClientProject].RowSource = “” ErrorHandlerExit: Exit Sub Er ...
Dim strProjectCode As String Dim strSearch As String Dim strSQL As String Dim frm As Access.Form Dim strForm As String Create a ...
ErrorHandler: MsgBox “Error No: “ & Err.Number _ & “; Description: “ & Err.Description Resume ErrorHandlerExit End S ...
FIGURE 7.16 An Excel timesheet filled with data from Access. The CreateExcelTimesheetsprocedure listed as follows first sets up ...
Dim appExcel As Excel.Application Dim dteWeekEnding As Date Dim lngCount As Long Dim lngEmployeeID As Long Dim n As Long Dim rng ...
Get the template path that was selected on the main menu: strTemplate = _ “Weekly time sheet by client and project.xlt” strTempl ...
Count the number of records for this employee: .MoveLast .MoveFirst lngCount = .RecordCount Create a new workbook from the templ ...
Process different project hours for the same employee on the same worksheet. Check for extra hours worked on Monday: If Nz(![Mon ...
Enter hours in regular Monday row: Set rngPC = _ appExcel.ActiveCell.Offset(columnoffset:=3) Set rngRH = _ appExcel.ActiveCell.O ...
Set appExcel = Nothing MsgBox “All time sheet workbooks created in “ _ & strDocsPath ErrorHandlerExit: Exit Function ErrorHa ...
O utlook has a great interface for working with calendars, contacts, and tasks, as well as for sending email messages. But Outlo ...
«
7
8
9
10
11
12
13
14
15
16
»
Free download pdf