If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Refresh a subform after an Append Query
Access XP running on WinXP sp2
Using a tabControl, on one of the tabs have two subforms. in the first subform, I select three items from comboboxes and enter a numerical value in a text box. values are then used to fill an append query along with identifying customer information from the main form containing the tabControl. a cmd buttom runs the VBA for the query. on the second subform, the results are displayed in DataSheet view. the append query runs correctly, the problem is the DataSheet does not update and display the new record. second subform's record source is a select query, which I open and close after the Append query runs. have tried me.requery; me.refresh; coresponding DOCMD's to no avail. any suggestions other that opening and closing the whole form? Thanks in advance; |
#2
|
|||
|
|||
Refresh a subform after an Append Query
If I understand correctly, you have a main form with two subforms and you
want actions in the first subform to requery the second subform. One way to do this is to create a public procedure in the main form that refreshes the second subform: Public Sub RefreshSub2() Me.SubformControl2.Requery End Sub Then call this procedure from the first subform after the data has been changed: Forms!MainForm.RefreshSub2 Stu M wrote: Access XP running on WinXP sp2 Using a tabControl, on one of the tabs have two subforms. in the first subform, I select three items from comboboxes and enter a numerical value in a text box. values are then used to fill an append query along with identifying customer information from the main form containing the tabControl. a cmd buttom runs the VBA for the query. on the second subform, the results are displayed in DataSheet view. the append query runs correctly, the problem is the DataSheet does not update and display the new record. second subform's record source is a select query, which I open and close after the Append query runs. have tried me.requery; me.refresh; coresponding DOCMD's to no avail. any suggestions other that opening and closing the whole form? Thanks in advance; -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200701/1 |
Thread Tools | |
Display Modes | |
|
|