DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: run time error 13, vb6 & ms access

  1. #1
    Join Date
    Aug 2009
    Posts
    1

    Question run time error 13, vb6 & ms access

    hola!
    i'm new in vb6.
    now my program is almost done.
    but i have a problem about data type, maybe.
    my program is use to enter data and save in database.
    i have compiled it and gave it to my friend to enter data.
    i divide the data with my friend so i can finish the work in short time.
    i want to combine all data in my computer.
    so i copy and paste data taken from my friend into my db.
    then i run the program.
    the run time error message box appeared and close the program.
    i try to debug and had detect the error.
    i leave the code as comment and try run the program.
    the program can run.
    i use list view to view my data. all data viewed in the list view only the column that have error because i leave as comment.
    i have checked the data type in db and it is correct.
    but i don't know what is the problem the program can't run
    the data input in the field include letter and number.
    there is another field that have letter and number too but still can view in the list view.
    i don't know what to do with this
    can anybody help me?

  2. #2
    Join Date
    Feb 2006
    Posts
    133
    Hi,

    first of all we need some more information, because the error can be anything.

    1) What's the type of field in your database?
    2) How do you add this field in your listview? Using a variable?

    Now did you try to add a breakpoint on that line to view in runtime mode what the value is? Another tip is to add a messagebox with the value before you add it to your listview, so you can determine which record and which value is generating the error.

    Regards.

    Benjamin
    Benjamin

  3. #3
    Join Date
    Aug 2004
    Location
    Orange, California
    Posts
    1,263
    Check the Data. See if any of the records have no value in that field. If the Fields value is Null then this would generate an error in VB. Use the IsNull() function to check the value first. If it is null then set the column's value to an empty string(""). You should do this check for all fields in the database that allow nulls.
    Note: the IsNull() function should be applied the recordset's field object, before you assign the value to any kind of variable.

Similar Threads

  1. Converting from access 2002 to access 97
    By wwwursa in forum Database
    Replies: 1
    Last Post: 03-07-2009, 02:20 PM
  2. Run time error....
    By Rnatarajan1 in forum ASP.NET
    Replies: 5
    Last Post: 01-24-2008, 02:05 AM
  3. storing the current time in an access database
    By caramia in forum Database
    Replies: 2
    Last Post: 05-13-2007, 07:32 PM
  4. Can VB6 still access encrypted DB?
    By Shannon in forum VB Classic
    Replies: 2
    Last Post: 02-23-2003, 04:10 AM
  5. Moving from Access 97 to Access 2000 with VB6
    By Dean Earley in forum VB Classic
    Replies: 2
    Last Post: 05-31-2002, 07:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center