devxlogo

August 9, 1997

Avoid Redundant Execution of Code

Most collections are zero-based. The COUNT property returns thenumber of members of a collection, as opposed to the highest membernumber. So when we see code that loops through all the

Set Forms to Nothing with Caution

It’s a good idea to set your form variables to Nothing to recoverall memory that was allocated for the form module. Executing SetForm1 = Nothing for a loaded form, however,

RegEdit Addition “Automation”

This sample file from Microsoft allows a more automated Windows95 Registry Addition. You can create a similar file in Notepador your favorite text editor, replacing the appropriate entriesin place of

Sizable Forms Without a Title Bar

If you set a form properties caption to “” and controlbox to False, then a form with borderstyle 3 (fixed dialog) willdisplay without its title. Unlike borderstyle zero (none), itkeeps

Securing a Jet Database the Right Way

To secure a Jet database, you must purchase Access 2 for VB3/VB3-16or Access 95 for VB4-32 and follow these steps: Use the Access Workgroup Administrator to create a new workgroupwith

Editing the Regular Grid

The regular grid that comes with Visual Basic cannot be editeddirectly. However, this problem can be easily circumvented withone line of code: Private Sub Grid1_KeyPress(KeyAscii As _ Integer)Grid1.Text = Grid1.Text