none
Context Menu Registry RRS feed

  • Question

  • I am reposting my original question from the Windows Developer forum as they say it is an Access specific issue and not a general Windows Registry issue.

     

    I created some code which builds Context Menu

    Windows Registry Editor Version 5.00

    [HKEY_CURRENT_USER\SOFTWARE\Classes\Access.Application.12\shell\MyContextMenu]
    @=""
    "MUIVerb"="CARDA Database Tools"
    "SubCommands"=""

    [HKEY_CURRENT_USER\SOFTWARE\Classes\Access.Application.12\shell\MyContextMenu\shell]
    @=""

    [HKEY_CURRENT_USER\SOFTWARE\Classes\Access.Application.12\shell\MyContextMenu\shell\Compact]
    @="Compact"

    [HKEY_CURRENT_USER\SOFTWARE\Classes\Access.Application.12\shell\MyContextMenu\shell\Compact\command]
    @="msaccess.exe \"%1\" /compact"

    If it is created in the HKCU then it appears to then override the default New context menu item for Access -> "Microsoft Office Access 20XX Database" eliminating it

    If I create the exact same context menu in HKLM, then everything is fine, but the HKLM requires elevated permission which causes a major problem!

    Is there a way to create it in the HKCU, but retain the New "Microsoft Office Access 20XX Database" command?

    I should also specify that this was not an issue with Access 2007, but is now with 2010, 2013 and 2016.  With Office 2007 using HKCU does not override the New item.

    I was trying to determine which Registry Key was responsible for this item in the New submenu so perhaps I could recreate it in the HKCU in the hope that would be sufficient to make it appear once again.  Any advice would be appreciated.

    Thank you for any help.


    Daniel Pineault, 2010-2017 Microsoft MVP
    Professional Support: http://www.cardaconsultants.com
    MS Access Tips and Code Samples: http://www.devhut.net

    Friday, October 13, 2017 12:28 PM

Answers

  • Hello,

    I could reproduce the issue using your tool. After comparing the registry, I find the New item disappears because you add some empty value for [HKEY_CURRENT_USER\Software\Classes\Access.Application.15] and [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell]

    Here is the registry which works:

    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15]
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell]
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu]
    @=""
    "MUIVerb"="CARDA Database Tools"
    "SubCommands"=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu\shell]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu\shell\Compact]
    @="Compact"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu\shell\Compact\command]
    @="msaccess.exe \"%1\" /compact"
    

    Your database created:

    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools]
    @=""
    "MUIVerb"="CARDA Database Tools"
    "SubCommands"=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Compact]
    @="Compact"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Compact\command]
    @="msaccess.exe \"%1\" /compact"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Decompile]
    @="Decompile"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Decompile\command]
    @="msaccess.exe \"%1\" /decompile"

    After delete the empty value for [HKEY_CURRENT_USER\Software\Classes\Access.Application.15] and [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell] , the issue would be fixed. 

    Regards,

    Celeste


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, October 25, 2017 10:19 AM
    Moderator

All replies

  • Hello,

    Do you mean Windows Context Menu?

    I tried to add the registry for Access 2007, but it makes no difference. Could you please share detail repro steps?

    Regards,

    Celeste 


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, October 16, 2017 3:11 AM
    Moderator
  • Celeste,

    Yes, that's the context menu.

    As I stated, the issue does not occur in Access 2007.  So in Office 2007, the behavior is absolutely fine.  Even after adding my reg keys the default Windows context menu remains just fine.

    It is with Office 2010+ that once you make the changes that the New -> Microsoft Office Access Database will disappear.

    Obviously, when testing, the reg keys need to be adjusted accordingly to your office version.

    The entire issue is regarding a small utility I created, http://www.devhut.net/2016/11/02/windows-explorer-ms-access-database-right-click-context-menu/, it implements the above reg keys automatically.


    Daniel Pineault, 2010-2017 Microsoft MVP
    Professional Support: http://www.cardaconsultants.com
    MS Access Tips and Code Samples: http://www.devhut.net

    Monday, October 16, 2017 12:32 PM
  • Hello,

    It works fine for me with Office 2007-2016. 

    It would add CARDA Database Tools when right clicking a MS Access file, at the same time, in the desktop, the New -> Microsoft Office Access Database control is still there. 

    Please visit https://1drv.ms/i/s!AkcxDWH1nFmJpU3SxbOOfDPro4p1

    Office 2010 is MSI installation 64bit. Office 2013 is C2R installation 64bit. For Office 2016, I test MSI 32bit and O365 ProPlus 32bit/64bit. OS is Win 10.  

    What is your test environment? Could you reproduce the issue in different machines? 

    Regards,

    Celeste


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Tuesday, October 17, 2017 5:31 AM
    Moderator
  • Yes, the new version will work as I've switch the code from using the HKCU over to using the HKLM because of the problem.

    If you make the entries in the HKCU only, the New menu item will in fact disappear.  I've had this confirmed by others.  The HKCU somehow overrides this default menu item.


    Daniel Pineault, 2010-2017 Microsoft MVP
    Professional Support: http://www.cardaconsultants.com
    MS Access Tips and Code Samples: http://www.devhut.net


    Tuesday, October 17, 2017 10:35 AM
  • But i did not use the tool downloaded from your link. I just create a reg file using the code in your original post and change the version numbers for different Office versions. 

    Please visit https://1drv.ms/i/s!AkcxDWH1nFmJpU4gzDVU8Z3GqE7S 


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, October 18, 2017 1:40 AM
    Moderator
  • I'm not sure what to tell you at this point as the problem has been reproduced on multiple systems.

    Thank you for looking into the matter. 


    Daniel Pineault, 2010-2017 Microsoft MVP
    Professional Support: http://www.cardaconsultants.com
    MS Access Tips and Code Samples: http://www.devhut.net

    Wednesday, October 18, 2017 9:04 AM
  • Hello,

    You may contact the Microsoft professional support to troubleshoot the issue. You won't be charged if the support engineer determines that the issue is the result of a bug.

    To create an incident, you could visit

    https://support.microsoft.com/en-my/gp/contactus81?Audience=Commercial&SegNo=4&wa=wsignin1.0

    Regards,

    Celeste


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Wednesday, October 18, 2017 9:20 AM
    Moderator
  • Hi Daniel,

    Based on the conversion between you and Celeste, it seems this issue could not be reproduceable at Celeste’s side.

    If so, I would consider this issue related with Office Version and system environment.

    It seems this issue does not exist under Office 2016 under Win 10, would you mind create a such environment to make a test? If this issue still exists, it would be helpful if you could share us your Office specific build number and Windows system version build number.

    If you have any updates about this issue, please feel free to let us know.

    Best Regards,

    Edward


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, October 24, 2017 6:39 AM
  • I'm not running Win10, so it's not a Win10 issue.  The issue has been confirmed by others, so I don't know what to say right now for Office 2010-2016.  I myself have the issue on multiple VMs running Win7.

    My question was never to get a fix from Microsoft, simply unrealistic.  My question was how can I recreate the item?  There's got to be a way to add a New Access Database item to the New context menu, no?


    Daniel Pineault, 2010-2017 Microsoft MVP
    Professional Support: http://www.cardaconsultants.com
    MS Access Tips and Code Samples: http://www.devhut.net

    Tuesday, October 24, 2017 9:53 AM
  • Hello,

    I could reproduce the issue using your tool. After comparing the registry, I find the New item disappears because you add some empty value for [HKEY_CURRENT_USER\Software\Classes\Access.Application.15] and [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell]

    Here is the registry which works:

    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15]
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell]
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu]
    @=""
    "MUIVerb"="CARDA Database Tools"
    "SubCommands"=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu\shell]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu\shell\Compact]
    @="Compact"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\MyContextMenu\shell\Compact\command]
    @="msaccess.exe \"%1\" /compact"
    

    Your database created:

    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools]
    @=""
    "MUIVerb"="CARDA Database Tools"
    "SubCommands"=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell]
    @=""
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Compact]
    @="Compact"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Compact\command]
    @="msaccess.exe \"%1\" /compact"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Decompile]
    @="Decompile"
    
    [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell\CARDA Database Tools\shell\Decompile\command]
    @="msaccess.exe \"%1\" /decompile"

    After delete the empty value for [HKEY_CURRENT_USER\Software\Classes\Access.Application.15] and [HKEY_CURRENT_USER\Software\Classes\Access.Application.15\shell] , the issue would be fixed. 

    Regards,

    Celeste


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, October 25, 2017 10:19 AM
    Moderator
  • Thank you so very much Celeste.  I will look into all of this this morning.


    Daniel Pineault, 2010-2017 Microsoft MVP
    Professional Support: http://www.cardaconsultants.com
    MS Access Tips and Code Samples: http://www.devhut.net

    Wednesday, October 25, 2017 10:32 AM
  • Thank you Celeste.  My brief testing confirms your diagnostic/solution.  I can't thank you enough this will help many people!

    It is still very odd that this issue does not occur with Office 2007 though? 

    Thank you for spending the time on this!


    Daniel Pineault, 2010-2017 Microsoft MVP
    Professional Support: http://www.cardaconsultants.com
    MS Access Tips and Code Samples: http://www.devhut.net


    Wednesday, October 25, 2017 12:27 PM