LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 78
Default Macro created in XL2000 not working in XL97

I have created a simple addin to run a macro through a context menu.
It works fine in XL 2000 but does nothing in XL97. Even context menu
command and icon is not created. Is there different syntext for XL2000
and XL97?

Code as below.

Regards,
Shetty

Code:
In a module:

Sub cmdadd()
With CommandBars("Cell")
With .Controls.Add
.FaceId = 1183
.Caption = "Delete Star"
.OnAction = "DeleteStar"
End With
End With
end sub

Sub DeleteStar()
Selection.Replace "~*", "", xlPart, xlByRows, False
End Sub

In this workbook code panel:
Private Sub Workbook_Open()
Call cmdadd
End Sub
 
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
Excel 2007 working on files created with older versions Hello_It''''s_Me-CA Excel Discussion (Misc queries) 2 June 15th 09 10:45 PM
Linked spreadsheets created in 2003 but not working in 2007 Steve Excel Worksheet Functions 2 June 4th 09 04:33 PM
XL2000 stock price web query stopped working Matthew Guerreiro Excel Discussion (Misc queries) 13 May 30th 06 04:16 PM
Function in xl2003 not working in xl97 Adam Excel Discussion (Misc queries) 2 January 26th 05 03:19 PM
Workbooks.Open fails after upgrade to XL2000 from XL97 Dan Merchant Excel Programming 0 July 9th 03 11:03 PM


All times are GMT +1. The time now is 09:10 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"