Tip Bank

DevX - Software Development Resource

Available Network APIs

Question: I would like to know if I could obtain a listingof the functions in the netapi.dll file and howto declare them in VB. It would be mostappreciated. Answer: The

DevX - Software Development Resource

VB Decompiler

Question: Is there a decompiler for Visual Basic executables so that I can retrieve the original source code? Answer: Currently, there is only a decompiler for VB 3.0 and VB

DevX - Software Development Resource

Embedding Double Quotes in Strings

Question: I was wondering if there is a way to use a set of quotes in a vb string. Answer: If you put two double quotes into your string, VB

DevX - Software Development Resource

Inserting Control Characters

Question: How do I insert carriage return (Chr(13)) and line feed (Chr (10)) in a text box at run-time? Answer: Just use the ampersand (&) and add them to the

DevX - Software Development Resource

Type Mismatch Error

Question: I have an SQL statement in my program that looks like this:data3.recordsource = “SELECT id, date from reservations where (date = ‘” & maskededit1.text & “‘) and (id =

DevX - Software Development Resource

Detecting the Cancel Button

Question: In my “Save As” dialog box (from CMDIALOG.VBX), my OK button and Cancel button both save work. How do I recognize when the userpresses the Cancel button? Answer: One

DevX - Software Development Resource

Calling a Form’s Subroutines

Question: How can I call another Form’s subroutine? Answer: Under VB3 you can’t call another form’s subroutine. If you need to do this, put the sub into a .BAS module.

DevX - Software Development Resource

Searching Numerical Fields

Question: What it’s the correct SQl Statement to search an access database by a numeric field? I keep getting an invalid type error when I try to run the application.