Explorer Forms with a Single Keystroke

In this action-packed episode, Chris Weber shows you how to use AutoKeys, how to create a sorting form, and how to use AutoKeys to enable you to generate this sorting form with a single keystroke.

One of the things that amazes me about Microsoft Access is its tenacity. Access debuted back in the early 1990s and has been going strong ever since. Meanwhile, other products and entire languages have come and gone, are on their way out, or have had to take a completely different course to survive. You could claim that Delphi, an excellent tool and the first of the truly radical RAD tools, is quickly being supplanted by Java and .NET technologies; C++ has been superseded by C#; Visual Basic has been completely transformed to keep up with Microsoft’s .NET initiative. But Access just hangs in there, because it was well thought-out from the outset and there are times when it’s just the right tool for the job. Continue reading

Posted in Forms | Leave a comment

Control Your Subforms

It really doesn’t make any sense to save an Order without any details. Christopher R. Weber explains how, by enhancing your interface design, you can create an event that stops users from omitting the detail records.

Not every data integrity rule can be enforced through referential integrity. One of the features I really like about Access is its support of main forms with subforms. If you ever traced the events on a main form/subform (by using the Event History from the Northwind database, for example) you’d notice that once you’ve filled in all of the necessary fields on the main form and tabbed into your subform, the parent record is saved before the child record is created. For referential integrity purposes, this makes perfect sense, as it ensures that the parent record exists for the child records that your users are about to create. In fact, at this point your user could navigate to another record and leave the Order record without any detail lines at all. In a typical business, an Order without details doesn’t make any sense, but there’s no way to enforce this rule using Jet’s referential integrity. In this article, I’ll show you how you can prevent this from happening and add some neat features to your form along the way. Continue reading

Posted in Forms | Leave a comment

Eventful Formatting for Access Forms

Dynamically changing your form’s properties at runtime can often provide a better experience for your users. Rick Dobson shows you some secrets for dynamically changing your form’s background as it gains and loses focus, keeping subforms in view, and providing colorful feedback for data.

In last month’s issue of Smart Access, I took a look at manual and programmatic means of applying Conditional Formats on Access Forms. As easy and powerful as conditional formats can be to use, they expose just a very small subset of the full range of Access formatting features. One of the great strengths of Access is that you can implement nearly all formatting features at design time from a form’s Properties window. In recent versions of Access, Microsoft even resorted to exposing a form’s Properties window at runtime, but this window is potentially confusing for the typical user of many Access applications. Beyond that, the availability of the Properties window at runtime still doesn’t enable the form and form control properties to be changed dynamically at runtime. Continue reading

Posted in Forms | Leave a comment

Listing Conditional Formats

In 2005, Rick Dobson wrote an article on that included details on Conditional Formats on Access Forms. But whilst the article was great, Rick didn’t show all the code that he had prepared in his sample database. And its what he didn’t show that is of great interest as this information is very hard to find anywhere.

This was compiled by Garry Robinson in 2013

Why Bother

Conditional Formats are very powerful but they are hard to read and just as hard to find.  If you decide to apply complex rules, you need to document the equations and crazy color schemes that you have applied to the fields in your forms. Continue reading

Posted in Forms | Leave a comment

Conditional Formats on Access Forms

Conditional formats let you flag exceptional values or highlight important results to your users. Rick Dobson shows you several easy (and powerful) ways to implement conditional formats and lower the bar dramatically when implementing conditional formats.

The Access Properties window makes it a snap to format controls. However, the substantial number and multiple settings for form control properties make it challenging to implement conditional formats from code at runtime. But starting with Access 2000, conditional formats became much simpler to do from code–letting you format controls based on their value at runtime. Continue reading

Posted in Forms | Leave a comment