Results 1 to 4 of 4
  1. #1
    jeffhanner is offline Advanced Beginner
    Windows 10 Access 2019
    Join Date
    Sep 2022
    Location
    Lincolln, CA
    Posts
    40

    Using DoCMD.Showtoolbar

    I have a form with a button called Print Preview that opens a selected report in the Print Preview mode. For a particular User, I use DoCmd.Showtoolbar "Ribbon", actoolbarno in the login. Upon click on the Print Preview button the event sets the actoolbaryes. This results in only the Print Preview Group showing. When I exit the preview I want to go back to actoolbarno, however the events that I've tried on the form and button to include the "no" command only result in the all groups showing. I'm trying to find where to put the "no" command so that it hides the ribbon after the report is finished.



    Any help would be appreciated.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,902
    Did you try code in report Close event?
    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.

  3. #3
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,974
    As June indicated, use the Report_Close event
    If you want to see this in practice, have a look at my example app Control Application Interface (isladogs.co.uk)
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

  4. #4
    jeffhanner is offline Advanced Beginner
    Windows 10 Access 2019
    Join Date
    Sep 2022
    Location
    Lincolln, CA
    Posts
    40
    What you suggested worked properly. I was trying events on the form to select reports, not the reports themselves.


    Thank you.
    Last edited by jeffhanner; 11-16-2022 at 09:50 AM. Reason: Problem Solved

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

Similar Threads

  1. Replies: 2
    Last Post: 09-27-2016, 09:10 PM
  2. Replies: 1
    Last Post: 07-30-2015, 12:56 PM
  3. Replies: 6
    Last Post: 01-27-2015, 02:00 PM
  4. ShowToolbar Macro Action, display to left
    By imorgan22 in forum Forms
    Replies: 3
    Last Post: 09-23-2014, 01:58 PM
  5. Replies: 10
    Last Post: 03-12-2013, 01:41 PM

Tags for this Thread

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