Hidden Features Expressions vs. Code When is code not code? When it's an expression. What's the difference and who really cares? Let's explore.
Commentary Lightweight Forms? Just Don't Lightweight forms make your code harder to read and debug, but if your users have monitors with high enough refresh rates, they'll appreciate the effort.
Code Library Come Together Do you build strings in loops? Stop trimming the delimiter at the end of the loop. There's a better way.
Code Library Quoth thy SQL? Evermore! Solving the "O'Malley problem" with dedicated functions to sanitize our strings. Little Bobby Tables would be proud.
Commentary Building Your Library Thirteen years ago, I chose to maintain a folder of text files rather than a single Access database library. I've never once regretted that decision.
Professional Development Journey to Access: Part 3 A morass of Word documents and Excel workbooks--the invasive plant species of the Windows world--overgrowing your file system like so much digital kudzu.
Professional Development Journey to Access: Part 2 The weirdos who enjoy spending lots of time to avoid doing mundane tasks that only take a little time have their own special name: programmers. Welcome to our very weird club.
Professional Development Journey to Access: Part 1 Many of the best Microsoft Access applications are written by people with no formal background in software development. Your origin story starts here.
Tools My Favorite Things Here is a list of my favorite utilities, add-ins, OCX controls, and applications that I use when developing Microsoft Access applications.
Commentary Past is Prologue A personal reflection on my software development journey. There's more to creating great software than knowing how to write code.
Testing VBA Doc Tests: Advanced Features Let's take our doc tests to the next level. I'll show you how to use my custom DocTests function to test classes, private functions, and error conditions.
Testing Python-inspired Doc Tests in VBA Doc tests are not a replacement for unit or integration testing. But they do provide the best return on investment (ROI) of any type of test, mostly because the effort to write them is near zero.
Conventions VBA Squeeze Box I discussed previously the differences between passing by value and passing by reference. I now want to discuss how and when I use each in my own code.
Basic One if ByRef, and Two if ByVal Arguments in VBA are passed by reference by default. What does that mean? And what are the differences between passing by reference and by value?
Version Control Access Version Control: My Philosophy These rules are intended as a guiding philosophy. If I'm getting closer to meeting this vision, I know I'm moving in the right direction.
Version Control Putting It All Together I expanded on the original decompose.vbs script. The code below is the culmination of more than 50 individual changes and tweaks over 10+ years.
Version Control Exporting Queries for Version Control SaveAsText will export queries to text files, but calling those files "human-readable" is a stretch.
Version Control Tracking Table Structure Changes Another potential source of bugs is changes to the structures of our tables. This includes both local tables and linked tables that reside in our back-end.
Version Control Referencing references While we can use the VBA user interface to display the references, we can't rely on that approach if we want to automate exporting our Access binary file to text files. Luckily, there is a solution.
Version Control Tables to Text: Do it for the DVCS! Anything that can lead to a bug in your software belongs in version control. That includes local tables with design-time data.
Hidden Features Wherefore art thou, database properties? In my previous post, I talked about adding custom properties to the database object. I covered how to do it, but did not go into any detail about why you might want to do it. Let's remedy that now.
Hidden Features Database Properties for Thee The DAO Database object has a Properties collection. You can read through the list of properties to extract saved database options. You can also add your own properties to the object.
Version Control From Gibberish to Clarity So, how can we compare those database properties? By iterating through the database's .Properties collection, of course. Here is some sample code from my modified decompose.vbs script.
Version Control The Starting Point Before we can use a DVCS with our Access application, we need to convert the binary Access file into a series of text files. The best place to start (and where my journey began) is with this StackOverflow answer.