Results 1 to 7 of 7
  1. #1
    mainerain is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Sep 2018
    Location
    Maine, USA
    Posts
    146

    referencing a tab in Where Clause when opening a form


    Is it possible to reference a particular Tab in a particular Form in the "Where Clause" when opening a Form with a Click event?

  2. #2
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    Tabbed forms is a specific thing, as are tab controls (which have pages) as are navigation form tabs. All 3 mean something different. Which one are we talking about?
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  3. #3
    mainerain is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Sep 2018
    Location
    Maine, USA
    Posts
    146
    I didn't realize that. I created a form that contains tabs which each have Command buttons for opening other forms.

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,815
    Sounds like TAB CONTROL on a normal form. Unless it is a NAVIGATION FORM with embedded form that has buttons.

    Which is it?

    And No, referencing TAB in the context you describe makes no sense.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    mainerain is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Sep 2018
    Location
    Maine, USA
    Posts
    146
    I would say TAB CONTROL on a normal form. Never heard of NAVIGATION FORM. I'm still wet behind the ears... I know it sounds odd I just was wondering if it was doable.

  6. #6
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,815
    Why would you even think it is needed?

    NAVIGATION FORM is an option on the Create design tab.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  7. #7
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    I think you're saying you have a form with a tab control and it has pages (aka "tabs" but select a "tab" in design view and see what the selection type is on the property sheet - it is "Page"). Anyway, AFAIK, as long as this isn't a subform the same reference syntax applies as what's used for any other form control:

    Forms!NameOfYourForm.NameOfYourControl

    Referenced form has to be open of course, and not in design view. A tab control, its pages and controls on the pages are all children of the main form, as weird as that seems. In form code you can simply msgbox Me.nameOfControl where that control is on a page of a tab control on that form. Should be same behaviour from the query side I suspect.
    Can't imagine why you want to reference the "tab" in a query anyway. Would have thought it should be referencing a control/field.
    Last edited by Micron; 05-28-2019 at 01:51 PM. Reason: spelin and gramur

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

Similar Threads

  1. Replies: 5
    Last Post: 01-24-2015, 12:59 AM
  2. Replies: 9
    Last Post: 01-13-2015, 07:30 AM
  3. Opening Report using WHERE CLAUSE not working
    By babui386 in forum Reports
    Replies: 2
    Last Post: 02-28-2013, 06:15 PM
  4. Help on where clause of open form
    By Madmax in forum Access
    Replies: 5
    Last Post: 06-23-2011, 11:19 AM
  5. Referencing a form in a subform
    By 161 in forum Forms
    Replies: 3
    Last Post: 01-24-2011, 03:58 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