***NEW CUSTOMER OFFER***
Get 15 minutes of free Live Help!

Code Snippets + Tips

How to use VBA to minimize the Office 2007 Ribbon

Nov 27, 2009 in Microsoft Access, VBA | 7 comments

If you’ve ever wished you could keep the Office Ribbon, but automatically minimize it to conserve space, this VBA function is for you.  The same technique works for Microsoft Access, Microsoft Word, etc. The function includes two pieces of logic.  The first piece checks to … Tags: Application, Command, ribbon,...

read more

Use VBA to get the maximum lengths of values in a MS Access table

Nov 27, 2009 in DAO, Microsoft Access, Tables, VBA | 0 comments

If you’ve ever imported a text file or a Microsoft Excel worksheet into Microsoft Access, you have seen how Access defaults the text field lengths to 255 characters.  This VBA function will display the maximum length of the values currently in each field of a … Tags: CurrentDb, Debug.Print,...

read more

Put your MS Access database on autopilot

Oct 6, 2009 in Macros, Microsoft Access, VBA | 0 comments

Put your MS Access database on autopilot

This example shows how to use a command line switch and a scheduled task to start a Microsoft Access application unattended and run some logic automatically. Perhaps you need a switchboard form to appear for users when they open a database during the day, but … Tags: Application, AutoExec, autopilot, Command, command line...

read more

Remove replication from a MS Access database

Aug 4, 2009 in Arrays, Collections, DAO, Databases, Forms, Macros, Microsoft Access, Modules, Queries, Reports, Tables, VBA | 31 comments

This VBA function copies or imports all the objects and database startup properties from a Microsoft Access replicated database into an un-replicated database.  It removes tablename_Conflict tables and removes replication-related fields like s_GUID, etc. Background: The Microsoft support site describes some methods that can be … Tags: Application, Containers, Debug.Print, Documents, DoEvents, Fields, FileDialog, GetObject, Indexes, Properties, QueryDefs, Relations, replication, Scripts, startup options, system tables,...

read more

Use VBA to copy MS Access PivotTable values to the clipboard

Jul 7, 2009 in Automation, Microsoft Access, Microsoft Excel, PivotTables, VBA | 4 comments

Use VBA to copy MS Access PivotTable values to the clipboard

This function uses a combination of Microsoft Access, VBA, and Microsoft Excel to transfer the values from an Access form in PivotTable view to the clipboard.  It is a good example of automation using late binding. The Challenge My goal was to automate the process … Tags: Address, Application, binding, Borders, Cells, clipboard, Columns, DisplayAlerts, DoEvents, EntireRow.Delete, GetObject, GetSaveAsFilename, PasteSpecial, PivotSelect, Range, SaveAs, Timer, Workbook,...

read more

Live Chat Software