If you want to add or remove fill colors from chart.Try this macro -
Macro to add fill color
Sub add_fill_colors()
Dim cht As Chart
' change chart name here
Set cht = Sheets("Sheet1").ChartObjects("Chart 3").Chart
'add fill color to chart area
cht.ChartArea.Interior.Color = RGB(205, 104, 137)
' add fill color to Plot Area
cht.PlotArea.Interior.Color = RGB(205, 193, 197)
End Sub
Macro to remove fill color
Sub remove_fill_colors()
Dim cht As Chart
' change chart name here
Set cht = Sheets("Sheet1").ChartObjects("Chart 3").Chart
'Remove fill color from chart area
cht.ChartArea.Fill.Visible = False
'remove fill color from Plot Area
cht.PlotArea.Fill.Visible = False
End Sub
Macro to add fill color
Sub add_fill_colors()
Dim cht As Chart
' change chart name here
Set cht = Sheets("Sheet1").ChartObjects("Chart 3").Chart
'add fill color to chart area
cht.ChartArea.Interior.Color = RGB(205, 104, 137)
' add fill color to Plot Area
cht.PlotArea.Interior.Color = RGB(205, 193, 197)
End Sub
Macro to remove fill color
Sub remove_fill_colors()
Dim cht As Chart
' change chart name here
Set cht = Sheets("Sheet1").ChartObjects("Chart 3").Chart
'Remove fill color from chart area
cht.ChartArea.Fill.Visible = False
'remove fill color from Plot Area
cht.PlotArea.Fill.Visible = False
End Sub
I am glad that I saw this post. It is informative blog for us and we need this type of blog thanks for share this blog, Keep posting such instructional blogs and I am looking forward for your future posts.
ReplyDeletePaint for Mac