Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Creation of "floating" toolbar

Hi
I currently have a workbook that contains many different
worksheet (around 40).
At the moment each sheet is accessed via a hyperlink from
the main menu (on the 1st sheet). On each sheet there is
another hyperlink to return back to the main menu.

What I was wanting to do was create a "floating toolbar"
with a button which can link back to the main menu. I am
not very good at VBasic and don't know where to start.

Ideally the toolbar (or form) should open automatically
when the file is opened, and remain on the screen at all
times (it would also be good if it could be moved around
the screen). I could then add different buttons to the
toolbar to perform different functions (ie return to main
menu, save, close etc).

Also, is it possible to add some sort of code to a file,
so that whenever it is closed it automatically returns to
the main menu, saves,and then closes, so each time it is
reopened it is at the main menu??

Many thanks in advance

Dave Rey
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Creation of "floating" toolbar

go to tools=customize and in the dialog, there is a button to add a
toolbar. You can then customize it and attach it to your workbook.

here is some reference material:


The best way to do this is to create your custom menus with a macro in the
Workbook_Open event and delete them in the Workbook_BeforeClose event. This
way you are sure you have full control over the menus and that they are
pointing to the right code when they execute.

An alternate way is to use the Attach command in the the Tools=Customize
dialog in the Toolbars tab. This way, when your file is opened, if the
toolbar does not exist, it is created from the toolbar attached to the file.
It is still a good idea to remove the toolbar when you close the workbook by
using the Workbook_BeforeClose event.

Here is an article which talks about attaching toolbars:

http://www.microsoft.com/exceldev/articles/toolbatt.htm

Here is an article about creating commandbars with code:
http://msdn.microsoft.com/library/techart/ofcmdbar.htm

Here is another article or two you might find useful:
http://msdn.microsoft.com/library/ba...n_addins97.htm
http://msdn.microsoft.com/library/of...exceladdin.htm
http://www.microsoft.com/exceldev/tips/addins.htm
These are about distributing applications

http://support.microsoft.com/?id=159619
XL97: Sample Macros for Customizing Menus and Submenus

http://support.microsoft.com/?id=213550
XL2000: Sample Macros for Customizing Menus and Submenus


http://support.microsoft.com/default...02&Product=xlw
How to customize menus and menu bars in Excel

http://support.microsoft.com/default...b;en-us;166755
File Title: Customizing Menu Bars, Menus, and Menu Items in Microsoft(R)
Excel 97
File Name: WE1183.EXE
File Size: 58041 bytes
File Date: 06/20/97
Keywords: kbfile kbappnote
Description: This Application Note can help you learn techniques for writing
Visual Basic(R) for Applications code to customize menus in Microsoft Excel
97. This Application Note contains code examples that you can use with the
following elements: menu bars, menus, menu items, submenus, and shortcut
menus.

--
Regards,
Tom Ogilvy



"Dave Rey" wrote in message
...
Hi
I currently have a workbook that contains many different
worksheet (around 40).
At the moment each sheet is accessed via a hyperlink from
the main menu (on the 1st sheet). On each sheet there is
another hyperlink to return back to the main menu.

What I was wanting to do was create a "floating toolbar"
with a button which can link back to the main menu. I am
not very good at VBasic and don't know where to start.

Ideally the toolbar (or form) should open automatically
when the file is opened, and remain on the screen at all
times (it would also be good if it could be moved around
the screen). I could then add different buttons to the
toolbar to perform different functions (ie return to main
menu, save, close etc).

Also, is it possible to add some sort of code to a file,
so that whenever it is closed it automatically returns to
the main menu, saves,and then closes, so each time it is
reopened it is at the main menu??

Many thanks in advance

Dave Rey



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Control Charts: "Floating Maximum" Burnnie Holliday Charts and Charting in Excel 1 November 28th 09 06:31 PM
Control Charts: "Floating Maximum" Burnnie Holliday Charts and Charting in Excel 0 November 24th 09 10:26 PM
Diff. change headline in "Formatting" or "Outlining" toolbar? Bernd Oninger Excel Discussion (Misc queries) 1 November 10th 08 11:02 PM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
how can i save "floating cells" in an excel document?? floating cells-excel New Users to Excel 0 October 24th 06 12:44 AM


All times are GMT +1. The time now is 07:40 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"