Results 1 to 3 of 3
  1. #1
    Platinum Lounger
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    4,594
    Thanks
    0
    Thanked 27 Times in 27 Posts
    What is the RunCommand to add a record in a form?

    I solved it by setting the DataEntry property of the form to True to add a record and False to view all records in the form.

  2. #2
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts
    [quote name='patt' post='792604' date='09-Sep-2009 10:59']What is the RunCommand to add a record in a form?[/quote]
    Pat

    DoCmd.GoToRecord , , acNewRec

    will take you to a new record in a form where the "Data Entry" property is False, provided the "Allow Additions" property is true.
    Regards
    John



  3. #3
    Platinum Lounger
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    4,594
    Thanks
    0
    Thanked 27 Times in 27 Posts
    [quote name='johnhutchison' post='792626' date='09-Sep-2009 13:54']Pat

    DoCmd.GoToRecord , , acNewRec

    will take you to a new record in a form where the "Data Entry" property is False, provided the "Allow Additions" property is true.[/quote]
    Funny how you forget these things, thanks John.

    I have gone the other way though, it works well.

Posting Permissions

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