Tech Support Guy banner
Status
Not open for further replies.

Excel Addin error

3K views 4 replies 2 participants last post by  Keebellah 
#1 ·
Good morning everyone,
I have been running into a problem with my Excel Addin and custom UI
I am getting this error (Microsoft Visual Basic Application System Error &H80070057 (-214724809)) when I trigger the UI to display another TAB but, it only occurs with one tab, the others work fine.

Below is what I have in the UI:
All <tab .... work perfectly except < tab id="HCGR01" ......
When this one is set to Visible and enabled (and all the the buttons required ) too it throws the error the moment you click this TAB
You click away the error and all works perfectly.
When I run the code to disable this tab, no problem it just hides and no more issues until I trigger it to show up gaian and the error only occurs when I click the TAB or when I open the Addin for the first time AND this TAB is still set to visible and enabled
ALL the other tabs and buttons work and none of these throw an error.
I even moved the code for Tab id "HCGR02" to HCGR01 and I still get the error while the other ones never do.

Anybody any ideas?

The full XLM code is in the attached pdf file. I even mailed Ron de Bruin but haven't had an answer yet
 

Attachments

See less See more
#2 ·
Hi Keebellah,

Not sure if this will be useful but, what I tend to do when I need to add or remove buttons from a ribbon is, create them then copy the '.OfficeUI' file.

For example for lots of Macros that I have running under Outlook, users will be able to 'Check for updates' for when I release a new version. When they click on the Update button it triggers a Powershell script which will check their username and determine if they get the admin ribbon or a standard use ribbon. I created the two ribbons and saved the files separately.

When I need to 'install' the ribbon I just place it in their 'C:\...AppData\Roaming\Microsoft\office' folder. When Outlook (or Excel in your case) launches it will load the ribbon with it.

I have found this solution much better and easier than having to write the XML.

Hope this can be of some help.
 
#3 ·
Hi @DataBase,
I've never copied or update the UI file so I'll have to see if I can find how it's to be done. I'll have to check that out.

I don't know if your option would work for me because my Ribbon is constantly is constantly changing, buttons are enabled/disabled depending upon the select workbook which is opened. Like I mentioned all the other tabs (5 of them) work fine and appear and disappear accordingly.
It's just this one that throws the error. I renamed it but to no avail so I'm leaving it disabled and invisible at all times, it's just that it's nagging me, why this one and not the other ones?
I've change the order it appears but no difference. It's just plain weird.
 
#4 ·
Hey Keebellah,

The UI file solution is good but if you are constantly changing (enabling, disabling) buttons then it may not be, because you will have to create a new ribbon for each eventuality.

Any chance you can upload your workbook so I can have a play? it saves me from typing out the block of code you attached as a picture :)
 
Status
Not open for further replies.
You have insufficient privileges to reply here.
Top