Erays
04-13-2005, 12:46 PM
Sub BuildEdsMenuItem()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Create Rei Folders"
newCtrl.OnAction = "MakeEdsFolder"
BuildEdsMenuItem1
End Sub
Sub BuildEdsMenuItem1()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Initial Email and Save"
newCtrl.OnAction = "EmailRei"
BuildEdsMenuItem2
End Sub
Sub BuildEdsMenuItem2()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Supplement Email and Save"
newCtrl.OnAction = "EmailSupp"
BuildEdsMenuItem3
End Sub
Sub BuildEdsMenuItem3()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "TotalLoss Email and Save"
newCtrl.OnAction = "EmailTLA"
BuildEdsMenuItem4
End Sub
Sub BuildEdsMenuItem4()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Save Initial Rei"
newCtrl.OnAction = "SaveRei"
BuildEdsMenuItem5
End Sub
Sub BuildEdsMenuItem5()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Save Supplement Rei"
newCtrl.OnAction = "SaveSupp"
BuildEdsMenuItem6
End Sub
Sub BuildEdsMenuItem6()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Save Total Loss Rei"
newCtrl.OnAction = "SaveTotal"
End Sub
Sub DeleteEdsMenuItem()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Create Rei Folders" Then ctrl.Delete
Next
DeleteEdsMenuItem1
End Sub
Sub DeleteEdsMenuItem1()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Initial Email and Save" Then ctrl.Delete
Next
DeleteEdsMenuItem2
End Sub
Sub DeleteEdsMenuItem2()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Supplement Email and Save" Then ctrl.Delete
Next
DeleteEdsMenuItem3
End Sub
Sub DeleteEdsMenuItem3()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "TotalLoss Email and Save" Then ctrl.Delete
Next
DeleteEdsMenuItem4
End Sub
Sub DeleteEdsMenuItem4()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Save Initial Rei" Then ctrl.Delete
Next
DeleteEdsMenuItem5
End Sub
Sub DeleteEdsMenuItem5()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Save Supplement Rei" Then ctrl.Delete
Next
DeleteEdsMenuItem6
End Sub
Sub DeleteEdsMenuItem6()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Save Total Loss Rei" Then ctrl.Delete
Next
End Sub
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Create Rei Folders"
newCtrl.OnAction = "MakeEdsFolder"
BuildEdsMenuItem1
End Sub
Sub BuildEdsMenuItem1()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Initial Email and Save"
newCtrl.OnAction = "EmailRei"
BuildEdsMenuItem2
End Sub
Sub BuildEdsMenuItem2()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Supplement Email and Save"
newCtrl.OnAction = "EmailSupp"
BuildEdsMenuItem3
End Sub
Sub BuildEdsMenuItem3()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "TotalLoss Email and Save"
newCtrl.OnAction = "EmailTLA"
BuildEdsMenuItem4
End Sub
Sub BuildEdsMenuItem4()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Save Initial Rei"
newCtrl.OnAction = "SaveRei"
BuildEdsMenuItem5
End Sub
Sub BuildEdsMenuItem5()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Save Supplement Rei"
newCtrl.OnAction = "SaveSupp"
BuildEdsMenuItem6
End Sub
Sub BuildEdsMenuItem6()
Dim newCtrl As CommandBarControl
Set newCtrl = Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls.Add
newCtrl.Caption = "Save Total Loss Rei"
newCtrl.OnAction = "SaveTotal"
End Sub
Sub DeleteEdsMenuItem()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Create Rei Folders" Then ctrl.Delete
Next
DeleteEdsMenuItem1
End Sub
Sub DeleteEdsMenuItem1()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Initial Email and Save" Then ctrl.Delete
Next
DeleteEdsMenuItem2
End Sub
Sub DeleteEdsMenuItem2()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Supplement Email and Save" Then ctrl.Delete
Next
DeleteEdsMenuItem3
End Sub
Sub DeleteEdsMenuItem3()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "TotalLoss Email and Save" Then ctrl.Delete
Next
DeleteEdsMenuItem4
End Sub
Sub DeleteEdsMenuItem4()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Save Initial Rei" Then ctrl.Delete
Next
DeleteEdsMenuItem5
End Sub
Sub DeleteEdsMenuItem5()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Save Supplement Rei" Then ctrl.Delete
Next
DeleteEdsMenuItem6
End Sub
Sub DeleteEdsMenuItem6()
Dim ctrl As CommandBarControl
For Each ctrl In Application.CommandBars("Worksheet Menu Bar") _
.Controls("Tools").Controls
If ctrl.Caption = "Save Total Loss Rei" Then ctrl.Delete
Next
End Sub