View Single Post
 
Old 02-19-2023, 07:07 PM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,176
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

Rather than including in the ribbon code the Enabled=True, you need to use the attribute getEnabled and include a callback macro to work out whether the button is enabled or not

See Confused over getEnabled for Ribbon

Note that when fiddling with code AFTER the ribbon has loaded, you may discover the updated code doesn't execute. Either reload the ribbon or close/reopen the document containing the ribbon to ensure the code is working.
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote