this is the code i got when i filled a rectangle pink:
ActiveSheet.Shapes("Rectangle 1").Select
Selection.ShapeRange.Fill.ForeColor.SchemeColor = 45
Selection.ShapeRange.Fill.Visible = msoTrue
Selection.ShapeRange.Fill.Solid
so it appears that yours should be:
With ActiveSheet.Shapes("Rectangle 9")
.Fill.ForeColor.RGB = RGB(0, 0, 0)
End With
hope that helps somewhat

susan
On Aug 7, 3:17*pm, Mike <M...@discussions.microsoft.com> wrote:
> I have a rectangle in a spreadsheet, when I click on it I run a macro to do
> some things and I want to change it's color. *I have the following codebut
> it does not work:
>
> * * With ActiveSheet.Shapes("Rectangle 9")
> * * * * .Fill
> * * * * .ForeColor
> * * * * .RGB = RGB(0, 0, 0)
> * * End With
>
> What is wrong?