PC Review


Reply
Thread Tools Rate Thread

Custom toolbars in templates

 
 
D Riggins
Guest
Posts: n/a
 
      7th Dec 2008
I have created a custom toolbar in and Excel 2003 template. The toolbar has
buttons that execute VBA subroutines. The Toolbar seems to function properly
in the template, but when a new file is created from the template, the
buttons for the subroutines produce errors. It appears that the toolbar in
the new file is trying to execute the sub in the template. How do you make
sure custom toolbar buttons execute the VBA sub in the workbook created from
a template?
 
Reply With Quote
 
 
 
 
Spreadsheet Solutions
Guest
Posts: n/a
 
      7th Dec 2008
Well;

You must be sure to refer to right workbook.
The worbook that you want to have the code executed on, must be the active
workbook.

So, set good reference to your workbooks, or work with statements like
Workbooks(XYZ).Activate


--
Best regards;
Mark Rosenkrantz
--
Spreadsheet Solutions
Uithoorn
Netherlands (the country were they live some 18 feet beyond sea level)
--
E: (E-Mail Removed)
W: www.spreadsheetsolutions.nl
--


"D Riggins" <(E-Mail Removed)> wrote in message
newsC0D23C9-657B-4821-B0E5-(E-Mail Removed)...
>I have created a custom toolbar in and Excel 2003 template. The toolbar
>has
> buttons that execute VBA subroutines. The Toolbar seems to function
> properly
> in the template, but when a new file is created from the template, the
> buttons for the subroutines produce errors. It appears that the toolbar
> in
> the new file is trying to execute the sub in the template. How do you
> make
> sure custom toolbar buttons execute the VBA sub in the workbook created
> from
> a template?


 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      7th Dec 2008
Check your other post, too.

D Riggins wrote:
>
> I have created a custom toolbar in and Excel 2003 template. The toolbar has
> buttons that execute VBA subroutines. The Toolbar seems to function properly
> in the template, but when a new file is created from the template, the
> buttons for the subroutines produce errors. It appears that the toolbar in
> the new file is trying to execute the sub in the template. How do you make
> sure custom toolbar buttons execute the VBA sub in the workbook created from
> a template?


--

Dave Peterson
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
custom toolbars on templates Kimmie B Microsoft Word Document Management 1 5th Jul 2008 10:29 PM
Templates with custom toolbars & macros Carolyn Microsoft Word New Users 4 2nd Sep 2006 10:01 PM
Custom Toolbars lost when old templates deleted =?Utf-8?B?SnVsaWVH?= Microsoft Word Document Management 3 5th Aug 2004 06:24 PM
Using macros on custom toolbars in templates. Conan Kelly Microsoft Excel Worksheet Functions 2 2nd Aug 2004 02:28 PM
Templates and Custom Toolbars? Juan Microsoft Excel Misc 1 10th Mar 2004 02:06 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:02 AM.