Results 1 to 4 of 4
  1. #1
    sheusz is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    May 2015
    Posts
    193

    Custom Right Click Menu Paramaters

    I have built a custom right click menu that works great. However some users of the DB do not intuitively understand the difference in the print icons. The first print icon opens the print dialog box, whereas the second print icon (with the green tick) does an immediate print (which can be a disaster in a 200 page report, if they just wanted to print the current page). I'd like to change the text next to the icons to something more meaningful to make the commands clearer for the user.

    Is this possible using the code I have below or do I need a different approach?



    Click image for larger version. 

Name:	Screenshot 2022-06-01 160206.jpg 
Views:	21 
Size:	6.7 KB 
ID:	47957

    Code:
        ' build new right click print menu
        Dim NewRightClickPrintMenu As Object
        On Error Resume Next
        CommandBars("NewRightClickPrintMenu").Delete
        Set NewRightClickPrintMenu = CommandBars.Add("MyRightClickPrintMenu", 5, False, True)
        NewRightClickPrintMenu.Controls.Add 1, 247, , , True 'page setup"
        NewRightClickPrintMenu.Controls.Add 1, 15948, , , True 'print dialogue
        NewRightClickPrintMenu.Controls.Add 1, 109, , , True ' print preview
        NewRightClickPrintMenu.Controls.Add 1, 2521, , , True 'quick print
        NewRightClickPrintMenu.Controls.Add 1, 12499, , , True ' PDF
        NewRightClickPrintMenu.Controls.Add 1, 923, , , True ' close
    I have found this reference online, but it seems far more cumbersome.

    https://docs.microsoft.com/en-us/off...trol-or-report

  2. #2
    isladogs's Avatar
    isladogs is offline Access MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    6,204
    Why not remove the Quick Print item ...or just use the Print Preview ribbon?
    Colin Riddington, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I know I don't know, I keep quiet!

  3. #3
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,932
    since you are using the standard functionality, I don't believe you can change 'print' to 'print to printer' or 'send to printer' or similar
    similarly I don't think you can include a msgbox before printing along the lines of 'Are you sure you want to send this report to the printer?'
    So third option is remove it completely so user has to preview before printing.

    Otherwise you need to create your own control - see this link for how this can be done
    https://nolongerset.com/right-click-menus-in-access/

  4. #4
    sheusz is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    May 2015
    Posts
    193
    Thanks Ajax and Colin for your input. I think that I'll go with creating my own control. I thought about removing the Print item, but some users like it, and believe it or not, some users get confused by the ribbon when it pops up.

    Lots of users with different levels of aptitude.

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

Similar Threads

  1. Custom Menu System
    By Freddie81 in forum Access
    Replies: 3
    Last Post: 09-07-2018, 07:54 AM
  2. Custom shortcut menu ?
    By Lukael in forum Access
    Replies: 3
    Last Post: 02-08-2016, 11:50 AM
  3. Replies: 2
    Last Post: 05-27-2014, 11:32 AM
  4. Replies: 3
    Last Post: 04-19-2013, 07:09 AM
  5. custom shortcut menu help!
    By ninachopper in forum Access
    Replies: 5
    Last Post: 09-05-2010, 06:27 AM

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