Sub XPTO()
Dim mymenu
' The following line of code adds "Perso-Menu" as a new menu on
' the worksheet menu bar.
Application.MenuBars(xlWorksheet).Menus.Add "Perso-Menu", Before:=8
' Set mymenu to be the menu items.
Set mymenu =
Application.MenuBars(xlWorksheet).Menus("Perso-Menu").MenuItems
With mymenu
.Add Caption:="&Unfilter", OnAction:="File_unfilter" 'Adds Item1
.Add Caption:="&2 Teste", OnAction:="mymacro2" 'Adds Item2
.Add Caption:="&3 Teste", OnAction:="mymacro3" 'Adds Item3
.Add Caption:="&4 Teste", OnAction:="mymacro4" 'Adds Item4
.Add Caption:="&5 Teste", OnAction:="mymacro5" 'Adds Item5
.Add Caption:="&6 Teste", OnAction:="mymacro6" 'Adds Item6
.Add Caption:="&Caculation", OnAction:="Open_Cotation" 'Adds Item7
End With
CommandBars("Worksheet menu bar").Controls("Perso-Menu").Controls("2
Teste").BeginGroup = True
CommandBars("Worksheet menu bar").Controls("Perso-Menu").Controls("4
Teste").BeginGroup = True
CommandBars("Worksheet menu bar").Controls("Perso-Menu").Controls("6
Teste").BeginGroup = True
End Sub