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: 30
Default Extracting Custom Menu Code

I'm trying to reconfigure an XL95 workbook to work under XL97 (and
hopefully later versions.) The workbook has over 150 custom macros
accessed through a custom menu bar. I'm trying to copy the custom menu
bar headings and macro references into a spread sheet so as to
facilitate their insertion into a new menu bar.

Bob Phillips suggested that I use VB macro code like that below. If I
copy the code into a VB module, the macro name "nextlevel" does not
appear in the list of macros, and so I'm uncertain as to how to get the
macro to run. IS IT SUPPOSED TO APPEAR IN THAT LIST?

I'm also unfamiliar with the syntax for the name of the macro. All
macros that I have created never had anything within the parenthesis.
WHERE MIGHT I LEARN MORE ABOUT TEXT PLACED WITHIN ( ) ?

Thanks ... WindsurferLA


Sub nextlevel(ctlParent As CommandBarControl)
Dim ctl As CommandBarControl
iLevel = iLevel + 1
For Each ctl In ctlParent.Controls
iRow = iRow + 1
Cells(iRow, "A").Value = iLevel
Cells(iRow, "B").Value = ctl.Caption
Cells(iRow, "C").Value = ctl.OnAction
Cells(iRow, "D").Value = IIf(ctl.BeginGroup, "TRUE", "")
If ctl.Type = msoControlPopup Then
Cells(iRow, "E").Value = ""
Else
Cells(iRow, "E").Value = ctl.FaceId
End If
If ctl.Type = msoControlPopup Then
nextlevel ctl
End If
Next ctl
iLevel = iLevel - 1
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
Extracting a code Fiona Excel Discussion (Misc queries) 5 October 20th 08 03:50 PM
Custom Menu Help EAB1977 Excel Worksheet Functions 1 November 12th 05 01:02 AM
VBA - Disappearing custom menu and custom toolbar Peter[_50_] Excel Programming 2 December 2nd 04 06:09 PM
Custom Menu return to Excel Menu upon Closing VetcalcReport Excel Programming 2 August 2nd 04 02:59 PM
Custom Menu Bob Phillips[_6_] Excel Programming 0 May 7th 04 04:27 PM


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