Results 1 to 4 of 4

Thread: Adding Records

  1. #1
    Join Date
    Feb 2004
    Posts
    2

    Unhappy Unanswered: Adding Records

    I have several fields on a form and I need to be able to add the info from the fields to an existing table (in access 2000) as a new record. For example: Take the info from Text1 & Text2 and put it as new record in the table called 'Jobs' under the fields 'Received Date' (for text1) and 'Received Time' (for text2). I pretty much need to know how to access a table (add records, remove records, update/change records), but without having the table linked to the form or text boxes. Hopes this makes sense I'm not a noob, but certainly not an expert. Any help/insight will be appreciated. thanks

  2. #2
    Join Date
    Jul 2001
    Location
    NC
    Posts
    102
    Dear Nervous

    The sequence is: (1) Enter data into form, where everything is considered as characters. (2) press submit button on form to dump form data to program variables. (3) convert into dollars, volumes, counts into numbers, convert date and time into appropriate format, check for completeness and correctness of data. (4) Write SQL statement to input variables into database. You may also want to add extra data, such as date and time stamping to the SQL statement. (5) open connection to database with MSJet or ODBC (6) Execute SQL statement using ADO with exception checking in case of problems. (7) close connection (8) advise user data written into database, (9) clear form.

  3. #3
    Join Date
    Feb 2004
    Posts
    2
    I've actually just got it workin about five mins ago, thanks anyway though

  4. #4
    Join Date
    Jan 2004
    Posts
    184

    Re: Adding Records

    Try this control featured on download.com that I have been using that has made my life easier:

    http://www.geocities.com/scirocco_ha/DataControl.htm

    I bind my controls and that is it All the complexities of ADO are hidden from the user which is you.

    Then I can Navigate, Add New, Delete, Refresh, Search and Save Changes to my recordsets without any other code. That is really it, no other code is needed.

    This works in any environment VB, Access, VC++ etc...

    Let me know what you think.

    Originally posted by NervousHamster
    I have several fields on a form and I need to be able to add the info from the fields to an existing table (in access 2000) as a new record. For example: Take the info from Text1 & Text2 and put it as new record in the table called 'Jobs' under the fields 'Received Date' (for text1) and 'Received Time' (for text2). I pretty much need to know how to access a table (add records, remove records, update/change records), but without having the table linked to the form or text boxes. Hopes this makes sense I'm not a noob, but certainly not an expert. Any help/insight will be appreciated. thanks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •