SQL 2005 Databound Form



I just upsized a Access 2007 (accdb) and created linked tables to SQL 2005.
The form is databound to a query result of two joining tables. The form's
property sheet has Recordset Type = Dynaset, Fetch Defaults=Yes. The form
has an Add New button with embedded macro (GoToRecord , , new).
This worked fine before the upsizing. Now clicking the same button, I got
"You can't go to the specified record". I change the button On Click event
to an Event Procedure like the following. I still get the same error
(Runtime error 2046, 2015). Please help.

Private Sub Command91_Click()
DoCmd.GoToRecord acDataForm, "frmTransferForm", acNewRec
End Sub

Tom van Stiphout

On Wed, 21 Oct 2009 16:48:01 -0700, Confused

Is that query updatable? If not, you may be missing some primary keys.

A form bound to a query joining two tables: unusual.

Microsoft Access MVP


Thank you for the reply. Could you tell me what is the usual way to
design form where the data source is from a joined tables query?
Should this be splitted into master and sub forms? Should it be based
on a SQL PassThrough query, and have a Instead Of Trigger on the SQL
Server to process the new record insert? Thank you and have a nice

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question