Add chart via code

  • Thread starter Thread starter Scott
  • Start date Start date
S

Scott

Inside of a WPF project written in C# I'm creating a new PPT presentation via
the interop libraries provided by installing Vistual Studio 2008 (so I guess
that's VSTO 3.0)

I've created the ppt file without issues, but I can't figure out how to add
a chart to a slide. I've got all the data that I want, but when I call the
add chart routine it doesn't seem to give me a way to set the data.

Can anyone provide an example of how to do this?
 
Inside of a WPF project written in C# I'm creating a new PPT presentation via
the interop libraries provided by installing Vistual Studio 2008 (so I guess
that's VSTO 3.0)

I've created the ppt file without issues, but I can't figure out how to add
a chart to a slide. I've got all the data that I want, but when I call the
add chart routine it doesn't seem to give me a way to set the data.

Can anyone provide an example of how to do this?

If the story in VS is the same as in VB/VBA, no. MS hasn't exposed the chart
object model in 2007.

Another approach might be to install MSGraph (which is available as a custom
install option in Office 2007) and use that. Or if Excel exposes the OM, you
might be able to automate it to create the chart and copy/paste or otherwise
insert that into PPT.
 
Steve Rindsberg said:
If the story in VS is the same as in VB/VBA, no. MS hasn't exposed the
chart
object model in 2007.

Nope, no magic addition to the OM via VS. What ya see is what ya get...


--
Austin Myers
MS PowerPoint MVP Team

Provider of PFCPro, PFCMedia and PFCExpress
www.playsforcertain.com
 
Nope, no magic addition to the OM via VS. What ya see is what ya get...

IOW, WYSIVBAIWYGIVSTO?

(what you see in vba is what you get in VSTO?)
 
Steve,
I think we have to wake up Cindy Meister who is now a VSTO MVP and was
a Word MVP who actually used Excel and PPT.

Yo, Cindy my darling
You listening?

Brian Reilly, MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top