Jump to content

VBA question regarding changing the colour of stacked columns


 Share

Recommended Posts

I hope everyone doesn't mind that I'm asking a question regarding vba in this forum, but Ozgrid is charging $1 for each topic!

Posted Image

In the above picture, I have a stacked bar graph. the first stack is light blue, the second is maroon, and the last is light yellow. How do I get vba to change those colours to what I want. I recorded macros for this but it doesn't work for stacked columns. The following is the code when I tried to record a macro.

With Selection.Interior
        .ColorIndex = 48
        .PatternColorIndex = 1
        .Pattern = 1
    End With
    ActiveChart.PlotArea.Select
    With Selection.Border
        .ColorIndex = 16
        .Weight = xlThin
        .LineStyle = xlContinuous
    End With
    With Selection.Interior
        .ColorIndex = 56
        .PatternColorIndex = 1
        .Pattern = xlSolid
    End With

It said that the system doesn't support this operation.

Edited by ToyBoi
Link to comment
Share on other sites

I hope everyone doesn't mind that I'm asking a question regarding vba in this forum, but Ozgrid is charging $1 for each topic!

So, you thought you would run up the hosting bills for AutoIt instead?

Please don't use the AutoIt forums for off-topic questions. If you are a regular AutoIt user aside from this question, then you could probably get help in the Chat forum.

;)

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...