Custom button, code placement

G

Guest

Hi
I have created a custom button which I have placed on the toolbar. The
button converts the text in the selected cells to uppercase.

I saved the macro code in Visual Basic Editor - 'This Workbook' for Book.xlt
I have created in the XLstart folder on my PC (I want the button to be
available in all new workbooks as well as any others I may open).

Every time I create a new workbook, I get the 'This workbook contains
macros' warning because of my button. Does anybody have a decent solution to
this problem? - Either so that the macro warning is bypassed (I appreciate
disabling safety features is not ideal), or so the macro code isn't
specifically stored in a template but in the Excel program itself (as the
other standard toolbar buttons must be).
Thanks for any help
 
B

Bob Phillips

Store the macro in your Personal.xls file in the XLStart directory.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
T

Tom Ogilvy

You can drop your security level to one that doesn't alert you to the
presence of macros.

You can certify your code and accept your certificate as a trusted source

You can move your code to an addin and load the addin. (remove your
toolbar/code from the xlt.)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top