Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 564
  • Last Modified:

Why form won't open to a selected record

I have a form which the user can select a record from a combobox.  Then the following code is supposed to open the second form to the selected record.  Instead the 2nd form opens and all records are displayed.

???

Here's the code of the onclick event of the command button on the first form.

DoCmd.OpenForm "frmMatlsTransHeader", acNormal, , , acFormEdit, acWindowNormal, "[MatlsTransHeaderID]=" & Me.cboID

What am I doing wrong?
0
SteveL13
Asked:
SteveL13
1 Solution
 
Jim Dettman (Microsoft MVP/ EE MVE)PresidentCommented:
You passing it in the wrong argument.  Should be:

DoCmd.OpenForm "frmMatlsTransHeader", acNormal, , "[MatlsTransHeaderID]=" & Me.cboID

, acFormEdit, acWindowNormal

Jim.
0
 
SteveL13Author Commented:
Thanks.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now