devxlogo

Tip Bank

Copying Menu Objects Between Forms

One problem that occurs frequently is taking the menu structure from one form and placing it in another. Although my method of dealing with this dilemma requires a little effort,

ODBC Error Display

I have seen many posters in the VB newsgroups that say they have received an ODBC error message such as 3146, but can’t figure out why they got the message.

Set Cursor to Control by Default

Sometimes it is useful to set a cursor to determine control when a form is loading-after the form is done loading, the cursor stays on the control you have ordered:

A Better Substitute for GetModuleUsage

To synchronously shell an application from a 16-bit VB application, some people write code like this: Const HINSTANCE_ERROR% = 32Dim hInstChild As Integer’Shell program, if Shell worked, enter loophInstChild =

Entering Scientific Formulas

I have developed this technique to use when I program long formulas. First, I declare descriptive variables for the mathematical elements. I prototype the formula using the digit “1” as

Create Queries On the Fly

Use VB’s string-concatentation operator (&) to incorporate user input into SQL queries at run time. Assume, for example, that cboField is a combo box containing a list of fields in

Speed Tips

Reading data into and out of a VB program is straightforward. Most folks use the Input and Put statements in a For…Next loop. However, this straightforward technique takes time. Because