G
Guest
I'm trying to change the default of a combo box from my code. But everytime
i close it, it goes back to the previous typed in default. Bellow is my
code. I don't have any idea why it doesn't work. It changes the default,
but when i close it and open it, it doesn't keep the changes.
Thank you,
Private Sub cmb_squadron_UIC_AfterUpdate()
Debug.Print Me.cmb_squadron_UIC.DefaultValue
Debug.Print Chr(34) & Me.cmb_squadron_UIC.Value & Chr(34)
Me.cmb_squadron_UIC.DefaultValue = Chr(34) & Me.cmb_squadron_UIC.Value &
Chr(34)
Me.Refresh
DoCmd.Save acForm, "SquadronMenu"
End Sub
i close it, it goes back to the previous typed in default. Bellow is my
code. I don't have any idea why it doesn't work. It changes the default,
but when i close it and open it, it doesn't keep the changes.
Thank you,
Private Sub cmb_squadron_UIC_AfterUpdate()
Debug.Print Me.cmb_squadron_UIC.DefaultValue
Debug.Print Chr(34) & Me.cmb_squadron_UIC.Value & Chr(34)
Me.cmb_squadron_UIC.DefaultValue = Chr(34) & Me.cmb_squadron_UIC.Value &
Chr(34)
Me.Refresh
DoCmd.Save acForm, "SquadronMenu"
End Sub