Results 1 to 2 of 2
  1. #1
    Freddie81 is offline Competent Performer
    Windows 10 Access 2013 64bit
    Join Date
    Mar 2018
    Posts
    149

    Tab control for menu itm

    Hi Guys,



    I'm trying to design the main menu using labels for the main options and a tab control to group sub items.

    Click image for larger version. 

Name:	tabcontrol.PNG 
Views:	14 
Size:	174.4 KB 
ID:	35463

    The tab control is called tabPages.
    On the tab control I have 3 pages each with command buttons.

    When I click on the main item "Admin Tools" I want the tab control to only display the items on the pgAdminTools page.

    I'm using the following vba code

    Private Sub lblAdminTools_Click()
    'Set BorderStyles
    Me.lblAdminTools.BorderStyle = 1
    Me.lblCustomers.BorderStyle = Transparent
    Me.lblTransactions.BorderStyle = Transparent
    Me.lblInventory.BorderStyle = Transparent
    Me.lblReports.BorderStyle = Transparent
    Me.lblAbout.BorderStyle = Transparent
    Me.lblExitAccess.BorderStyle = Transparent

    Me.txtFocus.SetFocus 'Move focus to txtbox

    Dim ctlCurr As Control
    'Check each control to see if Tag matches
    For Each ctlCurr In Me.Controls
    If ctlCurr.Tag = "Transactions" Or ctlCurr.Tag = "Reports" Then
    ctlCurr.Visible = False
    ElseIf ctlCurr.Tag = "AdminUtils" Then
    ctlCurr.Visible = True
    End If
    Next ctlCurr
    End Sub


    When I clic on the Admin Tools item tho, it gives me a blank control.
    Click image for larger version. 

Name:	tabs1.PNG 
Views:	14 
Size:	200.3 KB 
ID:	35464

    Any help would be appreciated.

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,518
    What's in the tag property of the tab control itself, etc? Can you attach the db here?
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 9
    Last Post: 05-31-2017, 11:50 AM
  2. Replies: 10
    Last Post: 02-14-2015, 10:41 AM
  3. Menu with multiple sub menu's
    By Simtech76 in forum Forms
    Replies: 1
    Last Post: 04-30-2013, 02:30 PM
  4. Replies: 0
    Last Post: 09-25-2012, 09:16 AM
  5. Control properties for Menu Command
    By Pam Buckner in forum Access
    Replies: 1
    Last Post: 10-20-2011, 01:49 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums