Interactive Excel Chart in Powerpoint

Posted on 2007-10-10
Medium Priority
Last Modified: 2010-05-18
Dear experts.

I'm trying to make a scientific powerpoint slide which shows an excel chart interactivelly.

In excel, i've done the complex scientific calculation, and shows the result in a chart.
The chart can be changed by modifying several cells that contains the calculation's parameters.
Until here, it works fine interactivelly.

Now, I want to impress my students, by showing that chart in a powerpoint slide interactivelly.
I  tried to link the chart in powerpoint (http://www.pptfaq.com/FAQ00593.htm).
This way, the chart in the powerpoint's slide can be changed interactivelly, BUT,
only by changing the parameter in Excel's worksheet, which is ugly.

How can I change the parameters from power point so I don't need to switch to excel during the presentation ?
I think I need to put a slider in the slide, then link it to the particular excel cell.
I just don't know how to make it happen.

Please help.

Question by:Kocil
LVL 18

Expert Comment

by:Curt Lindstrom
ID: 20054453
Try to Copy and paste instead of Copy and Paste link. Save powerpoint file and close the Excel file. You should now be able to double click the chart and do changes in power point without opening the Excel file.


Author Comment

ID: 20061639
Hi epaclm,
That is possible while the powerpoint is in edit mode,
but not in slideshow mode.

LVL 38

Accepted Solution

jeverist earned 1000 total points
ID: 20062662
Hi Kocil,

>  put a slider in the slide, then link it to the particular excel cell

Yup, or Spinner control in this case.  Here's a routine to add to the Slide module of the Powerpoint presentation slide that you have Paste Special>Linked an Excel chart from your spreadsheet:

Private Sub SpinButton1_Change()
Dim xlApp As Object, wb As Object, ws As Object, shp As Shape

On Error Resume Next
Set xlApp = GetObject(, "Excel.Application")
On Error GoTo 0

If xlApp Is Nothing Then
    Set xlApp = CreateObject("Excel.Application")
End If

On Error Resume Next
Set wb = xlApp.Workbooks("xlChart.xls")
On Error GoTo 0

If wb Is Nothing Then Set wb = xlApp.Workbooks.Open("C:\xlChart.xls")

xlApp.Visible = True

Set ws = wb.Worksheets("Sheet1")

ws.[D6] = SpinButton1.Value


For Each shp In Me.Shapes
    If shp.Type = msoLinkedOLEObject Then
    End If
Next shp

End Sub

Change "C:\xlChart.xls" to your linked Excel chart and data.

This line:

ws.[D6] = SpinButton1.Value

sets your cel value (cell D6 in this example) to the value of the Spinner control.  In the example, the Spinner control was set to Max = 10, Min = 0.  Changing the Spinner moved a Bar Chart column up or down by 1.

Try this and see how it works for you.  After you see the example working you can experiment with differnet controls like the Slider.

LVL 21

Assisted Solution

GlennaShaw earned 1000 total points
ID: 20066332
Thanks so much for posting that snippet of code.  I've seen this question (or similar) so many times...

If you'd really, really like to impress, try www.xcelsius.com

Expert Comment

ID: 20658395
Forced accept.

EE Admin

Featured Post

NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

Question has a verified solution.

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

Lost Word File? Eagerly, need it back? Read ahead; this File Recovery guide is for you.
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.
This Micro Tutorial will demonstrate how to use a scrolling table in Microsoft Excel using the INDEX function.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

864 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