Add/Edit

Z

Zanstemic

I have a pulldown box that is link to a table for the list of selections.
Next to the box is an Add/Edit button that launches into the list table. When
I make changes to the table, the pulldown does not show the update until I
exit and relaunch the program.

Any suggestions are appreciated.
 
S

Stefan Hoffmann

hi,
I have a pulldown box that is link to a table for the list of selections.
Next to the box is an Add/Edit button that launches into the list table. When
I make changes to the table, the pulldown does not show the update until I
exit and relaunch the program.
Add a

cboPulldownBox.Requery

in the event code of the Add/Edt button.


mfG
--> stefan <--
 
Z

Zanstemic

Currently I have a macro in the onclick event that opens the form and does a
requery. The add/edit launches the separate form. After saving, I need the
combo box in the original form to update with the new information.

It seems that on the save of the add/edit form, a requery is required but
I'm not sure where.

Any other suggestions?
 
S

Stefan Hoffmann

hi,
Currently I have a macro in the onclick event that opens the form and does a
requery. The add/edit launches the separate form. After saving, I need the
combo box in the original form to update with the new information.
Instead of using a macro, create a event procedure for your button
(select [Event Procedure] instead of a macro in the property editor):

Private Sub cmdButton_Click()

DoCmd.RunMacro "NameOfYourMacro"

cboPulldown.Requery

End Sub



mfG
--> stefan <--
 
Z

Zanstemic

Does cboPulldown represent the combo box name or the control source of the
combo box?

Thanks again for all the help.

Stefan Hoffmann said:
hi,
Currently I have a macro in the onclick event that opens the form and does a
requery. The add/edit launches the separate form. After saving, I need the
combo box in the original form to update with the new information.
Instead of using a macro, create a event procedure for your button
(select [Event Procedure] instead of a macro in the property editor):

Private Sub cmdButton_Click()

DoCmd.RunMacro "NameOfYourMacro"

cboPulldown.Requery

End Sub



mfG
--> stefan <--
 
S

Stefan Hoffmann

hi,
Does cboPulldown represent the combo box name or the control source of the
combo box?
Yes, it's the name of your combo box to requery.

mfG
--> stefan <--
 
Top