Tip Bank

DevX - Software Development Resource

Avoid Hungarian Notation in Public Interfaces

Most coding standards recommend the use of Hungarian variable naming, which uses prefixes to indicate the variable’s type. However, these naming conventions usually should not be used in a component’s

DevX - Software Development Resource

Getting MAPI entryID’s From Outlook Folders

This tip is useful if you do Outlook automation with user created Outlook folders. These folders cannot be accessed by the GetDefaultFolder method usually employed in automation techniques. This snippet

DevX - Software Development Resource

Swap strings the fast way

Consider the usual way of swapping two strings: Dim s1 As String, s2 As StringDim tmp As String’ initialize the strings s1 = String$(1000, “-“)s2 = String$(1500, “+”)’ do the

DevX - Software Development Resource

Delete a folder and all its subfolders

The RmDir command can delete a directory only if it doesn’t contain files or sub-directories. If the directory you want to delete does contain other files or, worse, subdirectories it

DevX - Software Development Resource

Use Refresh, not DoEvents

The DoEvent statement should be used only to give other portions of your program to be reactive to the end user’s actions. Instead, many VB developers use it to force

DevX - Software Development Resource

Serializing and Deserializing Arrays

Suppose you want to store the movements of a chess game in a file so that when the program terminates, the users can resume it later from the same point.