Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 03-09-2023, 10:47 AM
Ddadoo57 Ddadoo57 is offline How to show or hide the QAT (Quick Access Toolbar) in vba ? Windows 11 How to show or hide the QAT (Quick Access Toolbar) in vba ? Office 2021
Advanced Beginner
How to show or hide the QAT (Quick Access Toolbar) in vba ?
 
Join Date: Feb 2023
Posts: 73
Ddadoo57 is on a distinguished road
Default How to show or hide the QAT (Quick Access Toolbar) in vba ?

Hello,



Is it possible to show or hide the QAT Quick Access Toolbar in vba ?

With the code Application.CommandBars.ExecuteMso ("MinimizeRibbon") we can hide the whole Ribbon but not only the QAT. Is there an idMso for the QAT?

Best Regards,
David
Reply With Quote
  #2  
Old 03-09-2023, 03:23 PM
Guessed's Avatar
Guessed Guessed is offline How to show or hide the QAT (Quick Access Toolbar) in vba ? Windows 10 How to show or hide the QAT (Quick Access Toolbar) in vba ? Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 3,975
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

Looks like it is possible in Word365 via the interface -
Move the Quick Access Toolbar - Microsoft Support

I'm not seeing a way to do this in Word 2016 and can't suggest a method via VBA
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote
  #3  
Old 03-10-2023, 12:50 AM
Ddadoo57 Ddadoo57 is offline How to show or hide the QAT (Quick Access Toolbar) in vba ? Windows 11 How to show or hide the QAT (Quick Access Toolbar) in vba ? Office 2021
Advanced Beginner
How to show or hide the QAT (Quick Access Toolbar) in vba ?
 
Join Date: Feb 2023
Posts: 73
Ddadoo57 is on a distinguished road
Default

Thank you very much for your feedback!

I can't do it for the standard QAT either. I tried with Application.CommandBars.ExecuteMso ("???") but i don't have the idMso for the QAT. The idMso "MinimizeRibbon" hides/displays all the tabs but not the QAT

With a custom QAT put in startup folder, I have a problem with startFromScratch="true" which hides all other standard tabs (except the custom ribbon)

Is there a solution?

Sincerely,
David
Reply With Quote
  #4  
Old 03-13-2023, 07:35 PM
Guessed's Avatar
Guessed Guessed is offline How to show or hide the QAT (Quick Access Toolbar) in vba ? Windows 10 How to show or hide the QAT (Quick Access Toolbar) in vba ? Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 3,975
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

I'm not sure where you are going with this project but it is generally considered poor form to disable/hide all the functionality that a user may have customised for their own purposes - such as the QAT and Normal.dotm template contents. I prefer my templates to augment the user experience rather than remove familiar capabilities - leading a horse to water rather than forcing them to drink. That being said...

Does startFromScratch hide the QAT too? I've never used that setting myself. If that appears to be the only way to hide the QAT then you could reinstate each of the various ribbon tabs with xml. Just include the idMso for each tab.

Another alternative might be to export the existing QAT as the template opens, then remove all buttons. A separate macro could then re-instate the exported QAT as you close the template. This might be quite complicated if there are multiple templates (Normal, attached or add-ins) which each carry QAT customisations.
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote
  #5  
Old 03-14-2023, 11:32 AM
Ddadoo57 Ddadoo57 is offline How to show or hide the QAT (Quick Access Toolbar) in vba ? Windows 11 How to show or hide the QAT (Quick Access Toolbar) in vba ? Office 2021
Advanced Beginner
How to show or hide the QAT (Quick Access Toolbar) in vba ?
 
Join Date: Feb 2023
Posts: 73
Ddadoo57 is on a distinguished road
Default

Good evening Guessed and thank you for your feedback!

Yes you are right, but it's not a question for me to disable anything from the user, on the contrary as you say, it to bring an added value to his experience.

The idea I had with a custom QAT was to be able to link it to the custom ribbon for the user. In fact, in the case I encountered, I had no more space on the latter, and creating an additional tab for only a few items (needed only from time to time and under specific conditions), was not very ergonomic for my taste.

By default, startFromScratch="true" displays only the custom ribbon and the custom QAT.

Great that you can reset each tab with idMSo, I hadn't thought of that, thanks for the info! I think it's a bit like the Backstage?

Yes the idea of importing the .qat export file is also interesting... but the simplest would be that MS creates us a idMso for the QAT, as Application.CommandBars.ExecuteMso ("MinimizeRibbon") works for a ribbon.

With that I wish you a very good evening,
David
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to add quick access toolbar in Excel Add-In? Mangesh1212 Excel 6 11-30-2018 02:05 AM
How to show FULL quick access toolbar? dylansmith PowerPoint 2 02-10-2018 12:53 AM
Quick Access Toolbar Word 13 namedujour Word 8 08-12-2015 10:37 AM
add macro to quick access toolbar TessaLee Word VBA 2 03-16-2011 06:31 PM
Quick Access Toolbar pmokover Word 0 10-30-2009 07:25 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:22 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft