Update Form

ivi77

New member
Local time
Today, 18:03
Joined
Mar 31, 2005
Messages
8
I have a button on a form that invokes an update query and updates student's information such as last name, first name, gender, etc, which is got from another table in another DB that is stored in the current DB as a link table. But what I want to do is refresh the form so that it displays the updated information.. I did something like this

Private Sub Image115_Click()
Dim sid As String
sid = Forms!mainscreen![sid#]
DoCmd.OpenQuery "UpdateBasicData"
DoCmd.Close acForm, "MainScreen"
DoCmd.OpenForm "MainScreen", acNormal, Forms!mainscreen![sid#] = sid
End Sub

Can anyone please help me on this as the line before "End Sub" is not working..... thank you
 
Private Sub Image115_Click()
Dim sid As String
sid = Forms!mainscreen![sid#]
DoCmd.OpenQuery "UpdateBasicData"
docmd.refresh (query)
 
thank you for the info
 
I guess bridge players do know all of the tricks
:)
 

Users who are viewing this thread

Back
Top Bottom