Modify Function Category Names and Contents

S

sweez

I have several UDFs that I used Application.MacroOptions to place in a
new function category that I named. I now want to rename the category
and to take some of the UDFs that I prevously associaed with that
category out. Does nyone know how to do this? Even if I remove all
the VBA code associated with the UDF and category creation and naming
the category and associated function are still listed. I can not seem
to find a good way to munipulate the names and contents of the
categorys that I created/ named. Thanks in advance for any help.
 
N

Norman Jones

Hi Sweez,

Try something like:

'============>>
Public Sub TestIt()
Dim sStr As String
Const sName As String = "Longevity"
Const sDescription As String = _
"My Function to calculate longevity"
Const sCategory = "My New Category"

sStr = ThisWorkbook.Name

Application.MacroOptions Macro:="'" & sStr _
& "'!" & sName, _
Category:=sCategory, _
Description:=sDescription
End Sub
'<<============
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top