G
Guest
Can I in Excel split one cell into 2 halfs and have each half filled wit a
seperate color?
seperate color?
Sub Macro1()
'
' Macro1 Macro
'
With Selection.Interior
.Pattern = xlPatternLinearGradient
.Gradient.Degree = 90
.Gradient.ColorStops.Clear
End With
With Selection.Interior.Gradient.ColorStops.Add(0)
.ThemeColor = xlThemeColorDark1
.TintAndShade = 0
End With
With Selection.Interior.Gradient.ColorStops.Add(1)
.ThemeColor = xlThemeColorAccent1
.TintAndShade = 0
End With
End Sub
Sub Macro1()
'
' Macro1 Macro
'
With Selection.Interior
.Pattern = xlPatternLinearGradient
.Gradient.Degree = 90
.Gradient.ColorStops.Clear
End With
With Selection.Interior.Gradient.ColorStops.Add(0)
.ThemeColor = xlThemeColorDark1 'First Color
End With
With Selection.Interior.Gradient.ColorStops.Add(0.49)
.ThemeColor = xlThemeColorDark1 'First Color
End With
With Selection.Interior.Gradient.ColorStops.Add(0.51)
.ThemeColor = xlThemeColorAccent1 'Second Color
End With
With Selection.Interior.Gradient.ColorStops.Add(1)
.ThemeColor = xlThemeColorAccent1 'Second Color
End With
End Sub