Change navigation tab on “Navigation Control” of Access?

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-25 17:39:03

问题


Here's my doubt, I have an Navigation Control called "navControl" that haves three tabs("Venda", "Metalização", "Injeção"), and I have one Check Box with three options, I need to change tab according the selected option.

I think I need to use DoCmd.BrowseTo, but don't know how :/

Someone can help me? Thanks


回答1:


You must set the Navigation Target Name to the name of the form each navigation tab opens in Properties/Data tab of the navigation control..

Private Sub YourOptionGroup_Click()
    With Me
        Select Case .YourOptionGroup.Value
            Case 1:
                DoCmd.BrowseTo acBrowseToForm, "Form1", "YourMainFormName.NavigationSubform"
            Case 2:
                DoCmd.BrowseTo acBrowseToForm, "Form2", "YourMainFormName.NavigationSubform"
            Case 3:
                DoCmd.BrowseTo acBrowseToForm, "Form3", "YourMainFormName.NavigationSubform"
        End Select
    End With
End Sub


来源:https://stackoverflow.com/questions/44529082/change-navigation-tab-on-navigation-control-of-access

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!