Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2004
    Location
    Texas
    Posts
    37

    Unanswered: Problem saving record from unbound form - A2K

    I've got an unbound form that, once completed, I would like to append the record to an existing table ... but I can't seem to get it to work ...
    any help is truly appreciated.


    Method 1:
    DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70


    Method 2: (rstinit is a recordset)

    rstinit.AddNew
    rstinit!action = Me.action
    rstinit!start_date = Now()
    rstinit!start_time = Now()
    rstinit![initiated by] = Me.[initiated by]
    rstinit!tester = Me.Combo21
    rstinit!fixture = Me.fixture
    rstinit!product = Me.product
    rstinit!description = Me.description
    rstinit!typeofrun = Me.Combo19
    If Check15 = True Then
    rstinit!goldbdavailable = True
    End If
    rstinit.close

  2. #2
    Join Date
    Feb 2004
    Location
    Dorset UK
    Posts
    147
    In the table, in the fields that are text, are any of them 'allow zero length' set to No ?

    If this is the case, are the fields on the form filled in ?

    It could be (maybe not) that a field on the form you have, has a null/blank/zero value. Do all the fields get filled in ?

    Like your fields, fixture,product and so on.....

    Ken

  3. #3
    Join Date
    Jan 2004
    Location
    Texas
    Posts
    37
    All fields are verified (no nulls) prior to reaching the saverecord point.

    Neither method creates a new record in the table ... I'm stumped.
    A2K - W2k
    Thanks & Regards
    Pete

  4. #4
    Join Date
    Aug 2003
    Location
    Argentina
    Posts
    465

    Re: Problem saving record from unbound form - A2K

    Originally posted by pltx2000
    I've got an unbound form that, once completed, I would like to append the record to an existing table ... but I can't seem to get it to work ...
    any help is truly appreciated.


    Method 1:
    DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70


    Method 2: (rstinit is a recordset)

    rstinit.AddNew
    rstinit!action = Me.action
    rstinit!start_date = Now()
    rstinit!start_time = Now()
    rstinit![initiated by] = Me.[initiated by]
    rstinit!tester = Me.Combo21
    rstinit!fixture = Me.fixture
    rstinit!product = Me.product
    rstinit!description = Me.description
    rstinit!typeofrun = Me.Combo19
    If Check15 = True Then
    rstinit!goldbdavailable = True
    End If
    rstinit.close
    Insert this line:
    rstinit.AddNew
    rstinit!action = Me.action
    rstinit!start_date = Now()
    rstinit!start_time = Now()
    rstinit![initiated by] = Me.[initiated by]
    rstinit!tester = Me.Combo21
    rstinit!fixture = Me.fixture
    rstinit!product = Me.product
    rstinit!description = Me.description
    rstinit!typeofrun = Me.Combo19
    If Check15 = True Then
    rstinit!goldbdavailable = True
    End If
    rstinit.Update <---------------------------

    rstinit.close
    Saludos
    Norberto

Posting Permissions

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