Private Sub chk_preferred_Click()
Me.Refresh
End Sub
Private Sub Form_BeforeUpdate(Cancel As Integer)
If txt_sum_preferred = 0 Then
MsgBox "You must select one supplier price as preferred", vbInformation, "Wait"
Cancel = True
ElseIf txt_sum_preferred < -1 Then
MsgBox "You can only select one supplier price as preferred", vbInformation, "Wait"
Cancel = True
End If
End Sub
|