Questions tagged [commandbar]
120 questions
0
votes
3 answers
Hiding Command Bar Right Click Options Excel VBA
I am trying to hide most of the application.Commandbar options when a user right clicks. But im getting a debug error sometimes. Usually it works smoothly but sometimes it doesn't so I cant work out why the error only happens now and again.
I…

ajr45
- 7
- 4
0
votes
2 answers
Hide Command Button in Word When Printing
I have a Word document with a series of of command buttons that toggle their corresponding rows of text between hidden and unhidden. I would like for the buttons themselves to be hidden when I print the document to a pdf. For some reason, some of…
0
votes
1 answer
Adding context menu for VS 2010 Add-In on loading
I'm creating an Add-In for Visual Studio 2010.
I want to add the context menu item to the tab during Add-In loading
(in OnConnect method of the Add-In):
I do know how to add the menus using CommandBars.
I already added commands into "Tools" and…

Werolik
- 923
- 1
- 9
- 23
0
votes
0 answers
Changing Command Bar Size in D365 2016
I'm trying to change the size of the command bar in a D365 2016 (v8.2) environment. We essentially want to make if smaller, and the buttons closer together. We recently migrated to a new server and now the command bar is larger:
I've looked into…

Craig Furlonger
- 1
- 1
0
votes
1 answer
CommandBarFlyout (WinUi 2.7) Highlighting Misbehavior Using Secondary Commands
I have a CommandBarFlyout implemented with Secondary Commands within Secondary Commands like so:
…

Blondie
- 9
- 2
0
votes
1 answer
Adding 'icon only' buttons to a custom context menu
Using Office 2019, Excel
How can I add 'icon only' buttons to a custom context?
I have this simple menu:
On Error Resume Next
CommandBars("MyBar").Delete
Dim cb As CommandBar
Set cb = CommandBars.Add("MyBar", msoBarPopup, , True)
Dim bItem As…

Guyglk
- 51
- 5
0
votes
0 answers
Change the font and background color of an Excel CommandBar
I have search online and in this forum for hours trying to find someone with a similar issue, but have been unsuccessful. I am trying to determine how to change the default background color and font color for an Excel CommandBar pop-up. Here is my…

Chris
- 5
- 3
0
votes
0 answers
command bar "workbook tabs" how to do to pick automatically
With my macro im using about 300 files. I want to do the summary of all these files in one file. I have the array formula to sum some staff. I just write a formula without opening each of the file. Anyway, let's assume that the formula…

Emilia Rajchel
- 85
- 6
0
votes
1 answer
CommandBar Buttons Hover
I am using the CommandBar Component to display links. (The buttons are href links).
I want to remove the underline from buttons when hover. Is it possible? enter image description…

Lirlev4
- 3
- 1
0
votes
1 answer
How to replace simplify code when calling command bar combobox
I have this code in a class module
Public WithEvents evtHandler As VBIDE.CommandBarEvents
Private Sub evtHandler_Click(ByVal CommandBarControl As Object, _
handled As Boolean, CancelDefault As Boolean)
On Error Resume Next
…

Elio Fernandes
- 1,335
- 2
- 14
- 29
0
votes
1 answer
MSACCESS - How to trigger the Excel's import/export wizard via VBA (CommandBarButton)
I have a form with a button that HAS to trigger the classic Excel's import/export wizard via VBA.
I tried to list all the CommandBar in order to identify the one i need and next the Excel's CommandBarButton, so i can use it for a function. i did…

Alex
- 113
- 1
- 14
0
votes
2 answers
Word CommandBars.ExecuteMso ("FileNew")
I am using the following command in Word VBA but in the latest version of Word 365 (version 2005):
Application.CommandBars.ExecuteMso ("FileNew")
but this does not give the same Backstage page as clicking File > New.
When you click File > New you…

David Price
- 11
- 4
0
votes
0 answers
How to find control button that was clicked inside submenu
I have menu with submenu made of control buttons:
Set MenuItem = .Controls.Add(Type:=msoControlPopup)
With MenuItem
.caption = "Code Type"
With .Controls.Add(Type:=msoControlButton)
.caption = "Lists"
.OnAction = "'" &…

kittu
- 6,662
- 21
- 91
- 185
0
votes
2 answers
UWP - CommandBar blank space under Buttons
This code generates a blank space, a misalignment and a misposition as you can see in the image.
…

Luca Benatti
- 175
- 3
0
votes
1 answer
Missing CommandBars.Item
using Microsoft.VisualStudio.CommandBars;
In the following sample.
var applicationObject = (DTE2)application;
var allCommands = ((CommandBars)applicationObject.CommandBars);
Simple question: Why am I missing allComands.Item[]?

Theun Arbeider
- 5,259
- 11
- 45
- 68