Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
Can somebody please help me before I really hurt my head ageist a wall.
I have an Excel worksheet that contains a toolbar that I have created. When I change or add anything to this toolbar and open the worksheet on another PC in the office (from a shared drive) none of the changes or additions to my toolbar are shown. I have tried attaching and de-ataching the toolbar through right clicking the toolbar and selecting customize. In fact here is the process that I perform Right click on the toolbar and delete my toolbar from the workbook Amend the toolbar Right click on the toolbar and add my toolbar back to the workbook Save the workbook Now, after completing the above process and I go to another office PC , none of my changes are shown. I also have this VB code to delete the toolbar on closing the workbook:- Private Sub workbook_beforeclose(cancle As Boolean) On Error Resume Next 'in case toolbar is absent Application.CommandBars(LP_Log).Close End Sub Is this correct, because if I open a new excel worksheet my toolbar is shown ! If it is correct, where within my VB script should I place this code?? I hope somebody can offer some help, as this is really bugging the life out of me. I am in no way an expert in Excel VB so please explain in simple terms !! Really appreciate any help Cheers |
#2
![]() |
|||
|
|||
![]()
Maybe your code should look more like this:
Option Explicit Private Sub Workbook_BeforeClose(Cancel As Boolean) Dim LP_Log As String LP_Log = "toolbarNameHere" On Error Resume Next Application.CommandBars(LP_Log).Delete End Sub It's difficult to tell what LP_log is. You may want to read Jan Karel Pieterse's notes at: http://google.com/groups?threadm=083...0a% 40phx.gbl In fact, Jan Karel wrote a different set of instructions that may help you avoid the problems associated with attached toolbars. http://www.jkp-ads.com/Articles/DistributeMacro00.htm Anthony wrote: Can somebody please help me before I really hurt my head ageist a wall. I have an Excel worksheet that contains a toolbar that I have created. When I change or add anything to this toolbar and open the worksheet on another PC in the office (from a shared drive) none of the changes or additions to my toolbar are shown. I have tried attaching and de-ataching the toolbar through right clicking the toolbar and selecting customize. In fact here is the process that I perform Right click on the toolbar and delete my toolbar from the workbook Amend the toolbar Right click on the toolbar and add my toolbar back to the workbook Save the workbook Now, after completing the above process and I go to another office PC , none of my changes are shown. I also have this VB code to delete the toolbar on closing the workbook:- Private Sub workbook_beforeclose(cancle As Boolean) On Error Resume Next 'in case toolbar is absent Application.CommandBars(LP_Log).Close End Sub Is this correct, because if I open a new excel worksheet my toolbar is shown ! If it is correct, where within my VB script should I place this code?? I hope somebody can offer some help, as this is really bugging the life out of me. I am in no way an expert in Excel VB so please explain in simple terms !! Really appreciate any help Cheers -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Placing a toolbar and it moves | Excel Discussion (Misc queries) | |||
Toolbar saving problem | Excel Discussion (Misc queries) | |||
custom toolbar w/ macro | Excel Discussion (Misc queries) | |||
Row Autofit problem Excel 2003 | Excel Discussion (Misc queries) | |||
"Drawing" Toolbar is inactive | Excel Discussion (Misc queries) |