CommandButton1_Click()
If TypeName(Selection) = "Range" Then
MsgBox "グラフを選択してから実行してください。", 16
Exit Sub
End If
With Selection.Border
.Color = RGB(79, 129, 189)
End With
With Selection.Format.Fill
.Visible = msoTrue
.BackColor.RGB = RGB(149, 179, 215)
.ForeColor.RGB = RGB(79, 129, 189)
.TwoColorGradient msoGradientVertical, 3
End With
End Sub
Private Sub CommandButton2_Click()
If TypeName(Selection) = "Range" Then
MsgBox "グラフを選択してから実行してください。", 16
Exit Sub
End If
With Selection.Border
.Color = RGB(192, 80, 77)
End With
With Selection.Format.Fill
.Visible = msoTrue
.BackColor.RGB = RGB(218, 150, 148)
.ForeColor.RGB = RGB(192, 80, 77)
.TwoColorGradient msoGradientVertical, 3
End With
End Sub
Private Sub CommandButton3_Click()
If TypeName(Selection) = "Range" Then
MsgBox "グラフを選択してから実行してください。", 16
Exit Sub
End If
With Selection.Border
.Color = RGB(155, 187, 89)
End With
With Selection.Format.Fill
.Visible = msoTrue
.BackColor.RGB = RGB(196, 215, 155)
.ForeColor.RGB = RGB(155, 187, 89)
.TwoColorGradient msoGradientVertical, 3
End With
End Sub
Private Sub CommandButton4_Click()
If TypeName(Selection) = "Range" Then
MsgBox "グラフを選択してから実行してください。", 16
Exit Sub
End If
With Selection.Border
.Color = RGB(128, 100, 162)
End With
With Selection.Format.Fill
.Visible = msoTrue
.ForeColor.RGB = RGB(128, 100, 162)
.BackColor.RGB = RGB(177, 160, 199)
.BackColor.RGB = RGB(177, 160, 199)
.TwoColorGradient msoGradientVertical, 3
End With
End Sub
Private Sub CommandButton5_Click()
If TypeName(Selection) = "Range" Then
MsgBox "グラフを選択してから実行してください。", 16
Exit Sub
End If
With Selection.Border
.Color = RGB(247, 150, 70)
End With
With Selection.Format.Fill
.Visible = msoTrue
.BackColor.RGB = RGB(250, 191, 143)
.ForeColor.RGB = RGB(247, 150, 70)
.TwoColorGradient msoGradientVertical, 3
End With
End Sub
Private Sub CommandButton6_Click()
If TypeName(Selection) = "Range" Then
MsgBox "グラフを選択してから実行してください。", 16
Exit Sub
End If
With Selection.Format.Line
.ForeColor.ObjectThemeColor = msoThemeColorText1
End With
With Selection.Format.Fill
.ForeColor.ObjectThemeColor = msoThemeColorAccent1
.ForeColor.ObjectThemeColor = msoThemeColorBackground1
.Solid
End With
End Sub