:: ADP, passing Form parameter Fails ::

  • Thread starter Ronald_2001 via AccessMonster.com
  • Start date
R

Ronald_2001 via AccessMonster.com

Hi,

In my ADP Database I store info of a few product_groups.
Each group has its own Access Form, but they all uses the same tables
(Main_table, look_up tables).
To restrict the recordsets (control sources for combo boxes) for a certain
product group, I use stored_procedures with one parameter: @prod_ID

Each Form has an invisible textbox wih an fixed value (=1, =2 or =3).
My intention is to pass this value to the parameter of the stored procedures
when the Form opens.
To do this I put this code into the OnOpen event of the Form:

Private Sub Form_Open(Cancel As Integer)
Me.InputParameters = "@prod_ID=" & "Me.[prod_ID]"
End Sub

But instead of displaying certain records and restricted controlsources for
the combo boxes,
a 'Enter Parameter' dialog window appears.
After entering a value the Form works like it should.

Do I have to put the code in an other event or is the code incorrect ?

Please help.

Ronald


Then it should display only those relevant

When I open a Form, for lets say Product A,

am filtering having which

To display
 

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

Top