Joshua Dalley
Joshua Dalley

Reputation: 339

MS Access 2010+ How to make the navigation tabs act as buttons to create a new record

I am currently using a navigation menu in MS access 2010. I decided to go with the horizontal tab with a vertical sub tab.

I can't seem to figure out how to make my ADD NEW CUSTOMER tab create a new record.

enter image description here

I don't see any option in the propriety sheet, nor do I see a way to connect a form to this tab with a blank record. I want to avoid having a button inside this subform for new record. I want the tab itself to act as a button. Is this possible?

any advice or guidance will be greatly appreciated!

Upvotes: 0

Views: 1537

Answers (2)

johnmark14a
johnmark14a

Reputation: 1

To do it natively in Access 2010, click the button on the left side that corresponds with the form you wish to attach. Then, in the Properties sheet, go to the Data tab. For the "Navigation Target Name", enter the name of the form (your forms should be available in the drop down menu).

Upvotes: 0

VBlades
VBlades

Reputation: 2251

Assuming you have a subform embedded on the tab to enter the new customer details, you can do something like on the Change event of your tab control:

Private Sub MyTabCtl_Change()

    'Replace 1 with the PageIndex of your tab.
    If Me.MyTabCtl.Value = 1 Then
        'sbf is your subform name.
        Me.sbf.Form.DataEntry = True
    End If

End Sub

That will set up the subform to take a new entry.

Upvotes: 1

Related Questions