Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2008

    Unanswered: How Write New Field Data From Form Entry Into A Separate Table

    I have a form which contains a listbox. When the user double-clicks on the listbox a 2nd form opens and the user can make a new record entry. On this 2nd form is a field named "txtChillN". When the user has made the entry into this 2nd form I want the value of "txtChillN" to be entered into an unbound table named "tblChills". The field name in this table is "ChillN'. How do I do this?

  2. #2
    Join Date
    Mar 2009
    Provided Answers: 14
    Here is one solution (among others):
    Dim strSQL as String
    strSQL = "INSERT INTO tblChills ( ChillN ) VALUES ( '" & Forms!<2nd form name>!txtChillN & "' );"
    CurrentDb.Execute strSQL
    Replace <2nd form name> by the name of the second form and remove the single quotes (') if ChillN is numeric.

    The second form must be open (not in design mode) for this to work.
    Have a nice day!

  3. #3
    Join Date
    Mar 2008
    Thanks. Got it!

Posting Permissions

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