John Viescas, author
On Apr 15, 2017, at 20:58, 'Bill Mosca' wrmosca@comcast.net [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:
Use the CheckNo's AfterUpdate event to set the Payment Type. This is air code so you might have to adjust the control names to match yours.
Private Sub Check_No_AfterUpdate()
If Len(Me. Check_No & "") > 0 Then
Me.Payment_Type = "Check"
Else Me.Payment_Type = "Cash"
End If
End Sub
Regards,
Bill Mosca,
Founder, MS_Access_Professionals
MS Access MVP 2006-2016
That'll do IT http://thatlldoit.com
My Nothing-to-do-with-Access blog
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com]
Sent: Saturday, April 15, 2017 11:06 AM
To: MS_Access_Professionals@yahoogroups.com
Subject: [MS_AccessPros] Need help with VBA code
Access 2010,
On a form there are 2 text boxes, "Check No" (it is number field) and then" Payment type" (it is text field). I need code for on got focus event of the" Payment type" to be = to Check if there is a value in "Check No" otherwise to be = to Cash
Thank you
Posted by: John Viescas <johnv@msn.com>
Reply via web post | • | Reply to sender | • | Reply to group | • | Start a New Topic | • | Messages in this topic (5) |
Tidak ada komentar:
Posting Komentar