I am attempting to create a Data Entry form (frmDataEntry) where I want to use a combo box (cmbYN) to determine the initial starting point. In this combo box the Row Source is: "";New Customer;Existing Customer.
In the form footer I have some Tabs where the tab in total istabFormFooter), and there are two selectable tabs (tabExistingCustomer), (tabNewCustomer).
Basically I am trying to use VBA code and IF/Then statements to accomplish this. Originally the form footer is invisible and I am using Code int he AfterUpdate event box. The code I am trying to get working just to make the form footer visible is this (and yes I know this is likely not even close but I don't know how to tie events into the combo box selection).
Private Sub cmbYN_AfterUpdate()
If cmbYN = "" Then
FormFooter.Visible = False
If cmbYN = [New Customer] Then
FormFooter.Visible = True
If cmbYN = [Existing Customer] Then
FormFooter.Visible = True
End If
End If
End If
DoCmd.RunCommand acCmdSizeToFitForm
End Sub
I would greatly appreciate any help/ideas. Haha, if not I will just put in buttons.
Thank you.
In the form footer I have some Tabs where the tab in total istabFormFooter), and there are two selectable tabs (tabExistingCustomer), (tabNewCustomer).
Basically I am trying to use VBA code and IF/Then statements to accomplish this. Originally the form footer is invisible and I am using Code int he AfterUpdate event box. The code I am trying to get working just to make the form footer visible is this (and yes I know this is likely not even close but I don't know how to tie events into the combo box selection).
Private Sub cmbYN_AfterUpdate()
If cmbYN = "" Then
FormFooter.Visible = False
If cmbYN = [New Customer] Then
FormFooter.Visible = True
If cmbYN = [Existing Customer] Then
FormFooter.Visible = True
End If
End If
End If
DoCmd.RunCommand acCmdSizeToFitForm
End Sub
I would greatly appreciate any help/ideas. Haha, if not I will just put in buttons.
Thank you.