Current location: Hot Scripts Forums » Programming Languages » Visual Basic » VB and Access, adding new records to table


VB and Access, adding new records to table

Reply
  #1 (permalink)  
Old 11-30-03, 06:41 PM
mikecompsci mikecompsci is offline
New Member
 
Join Date: Nov 2003
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
VB and Access, adding new records to table

i need to add records from text boxes that are on a form. i haven't programmed in VB in forever and i need some help. How do i add the text from the boxes to an existing table?
Reply With Quote
  #2 (permalink)  
Old 12-03-03, 09:20 AM
Emmanuel Emmanuel is offline
Newbie Coder
 
Join Date: Dec 2003
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Hi,

You have to use a database cursor linked to your Access table (Declare, Open and Close after you finished your VB instructions on the database).

Use it like an array to fill each column concerned by corresponding form fields values in indexing the name of the cursor (First column is 0, second is 1,...etc) :

NameCursor(3) = NameFormField6.text for instance

Then when all fields values you want to record have been coded like this, use add function of the cursor to add the new record to your database.
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding same fields to two tables one uses hashing and encrypting TechnoDreams ASP 0 10-29-03 02:26 PM
Date From Access 2000 Database Kaikki ASP 4 09-25-03 06:04 PM
type mismatch and update loop - HELP! seala ASP 1 09-22-03 05:27 PM
Problem in Deleting records from Access skchakri ASP 1 09-20-03 12:59 AM
mysql to access aspuser25 Database 2 09-16-03 11:01 AM


All times are GMT -5. The time now is 01:17 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.