?
Solved

Bar Chart Bar Color Change in MS Access 2007 Using VBA

Posted on 2012-03-23
4
Medium Priority
?
949 Views
Last Modified: 2012-04-27
I have a chart that was created in Excel 2007 and I want to recreate it in MS Access 2007 (WantChart.jpg).  What I have so far is very close I just cannot get the bars in each series value to be different colors (HaveChart.jpg).  Is there a way to change the bar color without changing the color for the entire series?
Thanks in advance,
Jim
WantChart.JPG
HaveChart.JPG
0
Comment
Question by:phonepagerfax
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 37757758
Open the chart normally, note the color of the bar you want to change
Open the Report/Form in design View
Double-click the chart (Now you are in "Edit Mode")
Right-Click the bar that has the same color as the bar in Normal View
Select: Format data series
Select your desired color....

This is a bit tricky, because if at any point if you click anywhere else, you will throw yourself out of edit mode, and have to double click the chart again

It may take a few tries, ...but after that it becomes easier.

;-)

JeffCoachman
0
 

Author Comment

by:phonepagerfax
ID: 37758045
Jeff,

That changes the color for the entire series of bars.  Can I change the color of a single bar in the series?  And can it be done using VBA?

Thanks,

Jim
0
 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 2000 total points
ID: 37758182
Oh, It was not clear that this was one series...

Then you have to do this:

Open the chart normally, note the color of the bar(s) you want to change
Open the Report/Form in design View
Double-click the chart (Now you are in "Edit Mode")
Click once one of the bars in the series that has the same color as the bar(s) in Normal View (This should highlight all the Points in the series)
Then click again on the ONE bar you want to change
(Now that ONE bar should be highlighted)
Now right-click that single bar and select: Format data POINT
Select your desired color....

Again, it is a little tricky, but with some trial and error , you should be OK

;-)

JeffCoachman
0
 

Author Comment

by:phonepagerfax
ID: 37758425
Jeff,

YES!  That is perfect.

You wouldn't happen to have some vba that could do this too?

Thanks,

Jim
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…
Suggested Courses

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question