Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Problem in Excel 2002 vs Excel 97


This code below works fine in Excel 97 on NT.
After one of our machines was upgraded to XP with Excel 2002 it sto
working with Run-time Error 5 on the second "With..." the first one i
OK:

Sub MakeToolBar()

With Application.CommandBars(1).Controls
.Add Type:=msoControlPopup, Befo=11
.Item(.Count).Caption = "GEF Fi&xes"
.Item(.Count).Tag = "GEF Fixes"
End With

With Application.CommandBars("Custom Popup 1").Controls
.Add Type:=msoControlButton, Befo=1
.Item(.Count).Caption = "Fix &Me"
.Item(.Count).OnAction = "FixMe"
End With
End Sub

Any help or ideas will be greatly appreciated.
Thank you.
E

--
ed_va
-----------------------------------------------------------------------
ed_vak's Profile: http://www.excelforum.com/member.php...fo&userid=2477
View this thread: http://www.excelforum.com/showthread.php?threadid=38342

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,290
Default Problem in Excel 2002 vs Excel 97

Ed,

The dots are missing in front of "Add" and "Item" in both
portions of the sub. The code won't run without them.

The first portion leaves a blank button on the menu bar and
renames the button to the right of it.

Excel cannot find the "Custom Popup 1" control.
I would have to assume it is missing or was renamed.

Regards,
Jim Cone
San Francisco, USA


"ed_vak" wrote in
message ...

This code below works fine in Excel 97 on NT.
After one of our machines was upgraded to XP with Excel 2002 it stop
working with Run-time Error 5 on the second "With..." the first one is
OK:

Sub MakeToolBar()

With Application.CommandBars(1).Controls
Add Type:=msoControlPopup, Befo=11
Item(.Count).Caption = "GEF Fi&xes"
Item(.Count).Tag = "GEF Fixes"
End With

With Application.CommandBars("Custom Popup 1").Controls
Add Type:=msoControlButton, Befo=1
Item(.Count).Caption = "Fix &Me"
Item(.Count).OnAction = "FixMe"
End With
End Sub

Any help or ideas will be greatly appreciated.
Thank you.
Ed
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Problem in Excel 2002 vs Excel 97


Jim,
Thank you for your reply.

Actually those dots are there.
Hovewer it does looks absolutely right that control is missing (keeping
in mind that machine was upgraded).

What should I check for and where on the other (unupgraded) mashines to
be able to find that control? What options I have? Is it something in
Add-Ins manager?

Thanks a lot. Your help and time are greatly appreciated.
Ed


--
ed_vak
------------------------------------------------------------------------
ed_vak's Profile: http://www.excelforum.com/member.php...o&userid=24779
View this thread: http://www.excelforum.com/showthread...hreadid=383421

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,290
Default Problem in Excel 2002 vs Excel 97

ed,

When you replace one Excel version with another, you lose any/all
of the Menu/Toolbar changes that were made in the older version.
Each application version has it's own set of command bars.
However, any custom command bar "attached" to a workbook created
in XL97 should be available in XL2002 when that workbook is opened.

The list of available Menus and Toolbars (built-in and custom) are
found in View | Toolbars | Customize | Toolbars(tab).

Menus/Toolbars are stored for:
Excel 97 in...C:\WINDOWS\User8.xlb
Excel 2002 in...
C:\Documents and Settings\user\Application Data\Microsoft\Excel\Excel10.xlb

(your mileage may vary)

Your best bet probably would be to start over in XL2002 and
create/build any custom command bars that you need.

Regards,
Jim Cone
San Francisco, USA



"ed_vak" wrote in
message ...
Jim,
Thank you for your reply.
Actually those dots are there.
Hovewer it does looks absolutely right that control is missing (keeping
in mind that machine was upgraded).
What should I check for and where on the other (unupgraded) mashines to
be able to find that control? What options I have? Is it something in
Add-Ins manager?
Thanks a lot. Your help and time are greatly appreciated.
Ed
--
ed_vak

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
PasteSpecial problem in Excel 2002 [email protected] Excel Programming 2 June 13th 05 10:12 AM
Excel 2000 to Excel 2002 problem Dave the slaphead Excel Discussion (Misc queries) 3 February 17th 05 06:17 PM
Excel 97 vs Excel 2002 (XP) Notification Problem with Exce 97 (2 Assadi Attoumani Excel Programming 0 June 30th 04 12:21 PM
Problem with Excel 2002 Doc Excel Programming 8 December 29th 03 03:52 AM
Excel 97 & Excel 2002 date problem FireatHome Excel Programming 0 August 5th 03 08:23 PM


All times are GMT +1. The time now is 11:58 PM.

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

About Us

"It's about Microsoft Excel"