Results 1 to 5 of 5
  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Linking word table and MS Graphs (Office 2003)

    I'm hoping loungers can help me with this problem.

    I have volunteered to write a report using data obtained from an audit.
    The recipients of the report asked for the data to be presented in tabular form and also in graphical form. The attached dummy document shows what the customer wants.

    When I created the document, I input all the data and produced the Word tables. I then created each graph using the method suggested in Word Help; select the whole table, click on Insert | Object|MS Graph Object and Word creates the graph using the data from the table. Great. However,I have to produce three reports, and using the system in the sample document, after I have input the new data for another customer, I then have to open each graph and update its data table to be the same as the data in the Word table. We're talking 54 pages of data here - so quite a lot of graphs.

    The question : Is there a way to produce the target output but where the graph alters as I change the Word table i.e the graph's the Word table as its data table? Hope there is!
    Thanks
    Silverback
    Attached Files Attached Files
    Silverback

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Linking word table and MS Graphs (Office 2003)

    I'd put the table in an Excel worksheet and create the chart there too. You can then copy each and use Edit | Paste Special with the Paste Link option in Word to place a table and chart in your document that are linked to the Excel table and chart. As you update the data in Excel, the other items will be updated automatically.

  3. #3
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Linking word table and MS Graphs (Office 2003)

    Hans
    Thanks for your reply although I was hoping there was another way to do this using only Word.
    Firstly, using the Excel method means I have to deliver another file (the Word doc and the Excel file) which is not particularly good for not too IT Literate customers. If they lose the Excel file, the Word document will not work properly - Correct? However, it the great scheme of things, it's not too much of a problem.
    More irritatingly, when I create an Excel chart, it is always created using 'Series 1' which appears in the Legend, and the chart columns are all in the same colour. To get rid of this, I have to enter the Chart Options | Format Data Series and set the 'Vary colors by point' option. Is there a way to make this a default for chart creation, please? (The document has 158 charts, so altering each one will be a pain.)
    Also, is there a way of setting column colours as defaults? (Excel insists on choosing a dark maroon on which it is very difficult to see the data label.)
    Thanks
    Silverback
    PS : Post writing the above. I have recorded a macro which does most of the above - can't get it to change one column colour, though, only all of them. Would still be interested to know if any of the items mentioned could be set as default. Thanks
    Silverback

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Linking word table and MS Graphs (Office 2003)

    Unfortunately, I don't know of a way to link a Microsoft Graph chart dynamically to a Word table.

    You can specify a custom colour palette for a workbook in Excel, in the Color tab of Tools | Options. The last two rows specify the colours used for charts.
    You can set up one chart the way you want, then specify it to be the default for new charts to be created:
    - Select Chart | Chart Type...
    - Activate the Custom Types tab.
    - Click on User-defined.
    - Click Add to add the current chart to the list of user-defined custom chart types.
    - Click 'Set as default chart' to make the current chart the default.

    The way to change the colour for a specific column in VBA is

    ActiveChart.SeriesCollection(1).Points(2).Interior .Color = vbRed

    If the Excel file is not sent with the Word document, the tables and charts cannot be updated any more, but they will still look OK. You can also break the links to the Excel file before sending it off, in the Edit | Links dialog.

  5. #5
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Linking word table and MS Graphs (Office 2003)

    Superb! All my problems solved.
    Thank you so much, Hans.
    Silverback
    Silverback

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •