[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

controlling colors in a pie chart

Posted on 2001-07-28
4
Medium Priority
?
263 Views
Last Modified: 2008-07-03
I want to create a pie chart that uses green to represent "low" values, yellow for "mod", and red for "high". Is there a way to do this?  A bar chart will do also.

Thanks,
jptu
0
Comment
Question by:jptu
4 Comments
 
LVL 4

Expert Comment

by:MacRena
ID: 6331152
Hello jptu,

First of all, I have never seen pie or bar charts native to Access.
I am not saying it can't be done, but I would export my data to Excel and use the charting that is native to that app.

But if I HAD to do it in Access, I can't think of a way to make a Pie, but if I were going to create a bar chart, I would design a Report with a Frame fraBackDrop (for background contrast)
with a Width = 6"
with a BackColor = Grey

Then put 3 textboxes on it.
txtFirst, txtSecond, and txtThird and place them on the Frame in the configuration that you would like them to appear on the Report.

Then in the Report's Open code I would test the value that you want each textbox to represent, and change their Width and BackColor properties accordingly.

This was a cool one to think through!  Thanks,
Mac
0
 
LVL 2

Expert Comment

by:hotbudare
ID: 6331503
I can't do nothing but give u a starting point. Assumig u r using A2K and that u name your pie chart PieChart, u could add code like the following in the Updated event of PieChart, after adding a reference to "Microsoft Graph 9.0 Object Library":

Dim g As Graph.Chart
Set g = Me.PieChart.Object
Stop

From this point on you'll have to experiment. I did try to and had to quit, but I'm sure this is the right track ...

Also, maybe asking in the Microsoft Office Topic Area(http://www.experts-exchange.com/jsp/qList.jsp?ta=msoffice) might help too ...

HTH/EQTA
T.S.U. Mario Osorio
Punto Fijo, Falcon, Venezuela

0
 
LVL 1

Accepted Solution

by:
TheNextStep earned 20 total points
ID: 6334687
In the record source for the graph, sort the values in ascending order to arrange them from lowest to highest.

Next, double click on the graph in design view to open Microsoft Graph 8.0 screen.  A pie chart will appear with a datasheet window.  You can change the colors of the pies by right clicking, and selecting format data point.  If there are not enough pies in the pie chart, add rows to the datasheet.

Your data will appear in the chart lowest to highest with the lowest value at 12 o'clock and the highest value at 11 o'clock.
0
 

Author Comment

by:jptu
ID: 6338936
TheNextStep- thank you!  It works beautifully.

-jptu
0

Featured Post

 [eBook] Windows Nano Server

Download this FREE eBook and learn all you need to get started with Windows Nano Server, including deployment options, remote management
and troubleshooting tips and tricks

Question has a verified solution.

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

If you’re using QODBC to update QuickBooks data from Microsoft® Access but Access is not showing the updated data, you could have set up QODBC incorrectly.
Windows Explorer let you handle zip folders nearly as any other folder: Copy, move, change, and delete, etc. In VBA you can also handle normal files and folders, but zip folders takes a little more - and that you'll find here.
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…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

830 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