Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pie Graphs on Reprts in Access 1

Status
Not open for further replies.

cheech25

Technical User
Jul 21, 2006
23
US
I am trying to do a simple pie graph with a couple of fields in my report from a table with maybe 6 feilds. When I use the wizard it is only allowing me to choose one field. Please help. :)

Thank You
 
Use the wizard to start and after it is finished, modify the Row Source property of the chart control to whatever you want displayed in your chart.

Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
I tried to change the record source. It still will not show any of the feilds I am selecting. Please help

Thank You
 
Try the "Row Source property of the chart control". There was no mention made of the "record source".

Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
I actually went to the Row source and chenged a few things. That is still not working. If possible can you kinda of walk me through it, by telling what you would do and how you go about adding fields step by step, if thatis not to much. I would really appreciate it.

Thank You
 
Copy and paste the SQL of the Row Source in a reply and tell us what you want displayed in ther chart. There is a property of charts to read the data across or down. You may need to change this property based on your data.



Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
this is what I want too show in pie and eventually maybe add more feild if the allocation changes.

Fixed Income Equity
45% 55%



This is what the code is giving me:
SELECT [Fixed Income],Count(*) AS [Count] FROM [Retricted Asset Allocation] GROUP BY [Fixed Income];

This is only showing the fixed income. When I look at the layout veiw, the whole pie is blue.



Thank You
 
For a Pie chart, I would expect records to be more normalized to look like:

[tt][blue]
[Asset] [Allocation]
=============== ============
Fixed Income 45%
Equity 55%
[/blue][/tt]

You could change your Row Source to a union query something like:
Code:
SELECT "Fixed Income" as Asset, [Fixed Income] as Allocation
FROM [Restricted Asset Allocation]
UNION ALL
SELECT "Equity", [Equity]
FROM [Restricted Asset Allocation];
You may need to add additional "unions" to the union query if you have more assets.


Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
Thank you so much. I gave you a star. That really really helped.

Thank You
 
Thanks for the star. If your fields really are named after Asset Types, you should consider normalizing the tables. However, if the pie chart has been your only stumblling block then you may not want to go through the effort.

Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top