Microsoft
Apple
Hardware
Software
Network
Shareware
Games Online
Live Scores - TV
Microsoft FAQ
»
Applications
»
Microsoft Office
»
Access
»
Create a graph in a Word doc from Access based on access table data
Create a graph in a Word doc from Access based on access table data
Hi
I have a graph/chart problem where I cannot find the proper, clean solution so far. Here is the setup:
- From Access, I create a Word doc in which there are a number of merge fields which I replace with data from tables in Access. This works fine
- Now in the Word doc, I'd like to add a chart/graph based on data on a table in Access
All the solutions i found either show how to do a graph on an Access report, or in an Excel sheet, and then copy it in Word. What I would like however, is:
- either create the graph directly in Word from my Access VBA code, and feed it the Access table data. I have however no idea how that should be done. it seems from the couple of macros I recorded that a graph in Word is an inline object fed from a file, which for me is not a "clean" solution
- or create the graph first in Access with the table data, and copy/paste it in Word. But here again, I found only example how to create a graph on an Access report as "base"
Questions:
- Isn't it possible to create directly a graph object in Access, WITHOUT any "base" object such as a report, and then to copy/paste it to Word ?
- Is it possible to feed data to an inline MS graph object in Word without creating the graph first as file ?
- Is it necessary/best to go over the intermediary step of an Excel spreadsheet ?
In other words, what do you reckon the best solution is for my setup ?
Thanks for your help.
Bernard
Solution: Create a graph in a Word doc from Access based on access table data
That is strange but thanks cause I am using this as well and at some stage am going to get an error. I will have to check why I do not. I think that I have made a mistake in copying the code for you as I took out bits in and around this.
in any case I you do not need the select. This below is enough to get the chart copied. Where Sheet 2 is the name of your sheet and Chart 1 is the name of your chart.
Application.Workshee
ts("Sheet2
").ChartOb
jects("Cha
rt 1").Chart.CopyPicture Appearance:=xlScreen, Size:=xlScreen, Format:=xlPicture
You can now shorten this based on what objects you have inialized.
Active
Exchange 2007 email tracking
Can I install only part of EBS 2008 - message server
Trying to delete certain folders on startup.
Command line parameter to delimit a txt into xls
wins server on windows server 2003 sp1. error 4224
MicroSoft LifeCam Install Error
deleteing contents of a Cfile
visual studio trial cannot download
Visual Studio 2008 (Visual Basic) Express Dialog Base Units Conversion
Need a FREE replacement for Visual Studio Pro 2008
Search all fields in MS access table
Migrating Gmail contacts and calendar to exchange
while initializing device VKD-windows protection error- restart- computer shuts down
Problem: Active Directory Domain removal
Raise 2GB limit in Exchange 2007
Add radio buttons to word document
Problem: Restore deleted user account on Windows 2003 Small Business Server
error opening installation log file vista
Access form layout tips
Error message whilst trying to move mailbox from Exchange 2003 to 2007
Problem: how to delete highlighted colored rows?
Fixing - Cannot perform an aggregate function on an expression containing an aggregate
how to change Access 2003 runtime dictionary language "French"
Outlook 2007 keeps asking for password - pop3
Problem: active directory forest trust setup problem?
Problem: Cannot remove inherited permissions in Exchange
Problem: can you upgrade from server 200 to 2003?
Problem: What IIS security hole allows mIRC trojans?
Child domain users and Parent domain Exchange
Problem: No duplicate item in combobox item