Combo Box After Update Event

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have the following code on two different forms which reference the table,
tblReturns.

Private Sub ActionID_AfterUpdate()
Me.Action = [ActionID].Column(2)
Me.ActionType = [ActionID].Column(1)
End Sub

This works perfectly fine on one form and whatever ActionID is selected in
the combo box, it puts the corresponding Action and ActionType in the
appropriate boxes. On the second form this only works for the ActionType and
does not fill in the Action. I have checked that both codes are the same, the
table is ok, the bound columns to the combo box are the same. Does anyone
have an idea what else I could check or what is going wrong?

TIA
 
I would check two things
1. The Row Source of the combo, does the SQL include the Action field?
2. The ColumnCount Property of the combo, has 3 in it
 
Thanks Ofer!

ColumnCount! I knew it was something simple!!


Ofer said:
I would check two things
1. The Row Source of the combo, does the SQL include the Action field?
2. The ColumnCount Property of the combo, has 3 in it

--
\\// Live Long and Prosper \\//
BS"D


albycindy said:
I have the following code on two different forms which reference the table,
tblReturns.

Private Sub ActionID_AfterUpdate()
Me.Action = [ActionID].Column(2)
Me.ActionType = [ActionID].Column(1)
End Sub

This works perfectly fine on one form and whatever ActionID is selected in
the combo box, it puts the corresponding Action and ActionType in the
appropriate boxes. On the second form this only works for the ActionType and
does not fill in the Action. I have checked that both codes are the same, the
table is ok, the bound columns to the combo box are the same. Does anyone
have an idea what else I could check or what is going wrong?

TIA
 

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

Similar Threads

Any obvious errors? 1
Compile Error 2
output to pdf 4
Set default value in different subform 5
pass data from subform to form 3
Retain combo box order 1
Combo Box & Report Questions 22
How to switch combo boxes? 1

Back
Top