Tip Bank

DevX - Software Development Resource

Selecting File from File List Box

Question: I put a drive box, a directory list box, and a file list box on the form, with the intention of being able to select an *.ico file from

DevX - Software Development Resource

Formatting a Disk

Question: How do I issue a disk format command from myVB code? Do I simply shell to DOS? Answer: That’s what I would recommend. Format is a .COM file, so

DevX - Software Development Resource

RecordCount Incorrect

Question: VB reports the wrong number of records from an Access database with the RecordCount property. The same query to dBase files reports the correct number of records. What is

DevX - Software Development Resource

Executing DOS Commands

Question: How can I run the following “SHELL” command in VB? It works fine in PowerBasic, but VB 3.0 doesn’t like it.SHELL “DIR *.BKP > FILES.LST”Any ideas? Answer: Try this:Shell

DevX - Software Development Resource

Using Ampersands in Labels

Question: I can’t seem to figure out how to place a “&” sign in a text field or in a label’s caption. Answer: Try putting two ampersands next to each

DevX - Software Development Resource

Putting Controls on MDI Forms

Question: I have a project I am working on including an MDIform with a toolbar. I am wanting to put a combobox on the toolbar, but VB4 will not let

DevX - Software Development Resource

Using ToolTips

Question: How do I program the ToolTips (text that appears when the cursor is over a toolbar button) ? Answer: You should look into the Tips control from Mabry Software.

DevX - Software Development Resource

Passing a Form to a Sub/Function

Question: How do I pass a form as an argument to a function or procedure? I have tried passing the the form name directly and the form name as a

DevX - Software Development Resource

Making a System Modal Message

Question: How can I make it so that a form will stay on top until the user presses a button? For example, an error message pops up, the user can’t