Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Common Errors

Posted on 2006-11-28
4
Medium Priority
?
184 Views
Last Modified: 2010-04-30
So far, from my novice experience in programming VB I have learned that some of my biggest errors come from 'incorrect values linking to the database.  From your experiences, what are some of the things you have experienced as the top problems encountered in VB design.
0
Comment
Question by:al4629740
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 29

Accepted Solution

by:
Nightman earned 1200 total points
ID: 18030340
1. Failure to check whether a recordset/object exists when before using it (Object variable or with block not set).
2. Failure to compile a project for repeated, upgradeable distribution with Binary comapatibility.
3. Iterating forwards through an indexed list deleting by index (array out of bounds).
4. Forgetting to destroy objects in memory, assuming (for some unknoen reason) that VB will clean up for you.
5. Not closing and destroying databse connection objects in memory.
6. Poor handling of null values.
7. Repeated re-use of shared source code instead of compiling into a single library.
8. And in team projects, failure to communicate properly with regards to change control over common source code/libraries.
9. Assuiming that the user would 'never to that'
...
0
 
LVL 9

Assisted Solution

by:dancebert
dancebert earned 400 total points
ID: 18030835
Assuming that the IsDate() function works as one would expect it to

? isdate("0221/01")
True
? IsDate("09-8453166")
True
? isdate("10/90")
True

0
 
LVL 15

Assisted Solution

by:cquinn
cquinn earned 200 total points
ID: 18036230
Users will tell you exactly what they want a system to do
Using an Int variable for a loop that can possibly happen > 32767 times
Declaring variable on a line assuming that all will be of the same type (the ones without as end up as variants) eg: Dim iLoop, iCount, iMax as Integer

0
 
LVL 44

Assisted Solution

by:Arthur_Wood
Arthur_Wood earned 200 total points
ID: 18036235
10. Failure to add Error Handling to EVERY procedure, religiously.
11. Failure to rename controls to be 'meaningful' (do not use the default names assigned by VB - TextBox1, TextBox2, Command1, Combo1, etc)

AW
0

Featured Post

Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question