Hi guys, everytime I start my db and want to start a macro this error pops up: "You have selected the expression ~ on click ~ as the setting for the event property. This printed caused an error. Object or class do not support this set of Events". My solution at the Moment is to switch to the Access design view and go back- now it works….
This is the Code that triggers the error:
This is the Code that triggers the error:
Code:
Option Compare Database
Private Sub Befehl16_Click()
Me!sf_qry_all.Form.FilterOn = False
End Sub
Private Sub Kombinationsfeld2_Click()
Me!sf_qry_all.Form.Filter = "Gruppe = '" & Me.Kombinationsfeld2 & "'"
Me!sf_qry_all.Form.FilterOn = True
Me.Kombinationsfeld2 = Null
End Sub
Private Sub Kombinationsfeld4_Click()
Me!sf_qry_all.Form.Filter = "Kategorie = '" & Me.Kombinationsfeld4 & "'"
Me!sf_qry_all.Form.FilterOn = True
Me.Kombinationsfeld4 = Null
End Sub
Private Sub Kombinationsfeld6_Click()
Me!sf_qry_all.Form.Filter = "Schulung = '" & Me.Kombinationsfeld6 & "'"
Me!sf_qry_all.Form.FilterOn = True
Me.Kombinationsfeld6 = Null
End Sub
Private Sub Kombinationsfeld8_Click()
Me!sf_qry_all.Form.Filter = "Schulung = '" & Me.Kombinationsfeld8 & "'"
Me!sf_qry_all.Form.FilterOn = True
Me.Kombinationsfeld8 = Null
End Sub
Private Sub Kontrollkästchen21_Click()
Me!sf_qry_all.Form.Filter = "[Nächster Termin] >= #" & Format(Date, "mm\/dd\/yyyy") & "# and [Nächster Termin] <=#" & Format(Date + 30, "mm\/dd\/yyyy") & "#"
Me!sf_qry_all.Form.FilterOn = True
Me.Kontrollkästchen21 = Null
End Sub
Private Sub Kontrollkästchen24_Click()
Me!sf_qry_all.Form.Filter = "[Nächster Termin] <= #" & Format(Date, "mm\/dd\/yyyy") & "#"
Me!sf_qry_all.Form.FilterOn = True
Me.Kontrollkästchen24 = Null
End Sub
Private Sub Text26_AfterUpdate()
Me!sf_qry_all.Form.Filter = "Nachname = '" & Me.Text26 & "'"
Me!sf_qry_all.Form.FilterOn = True
Me.Text26 = Null
End Sub