LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming,microsoft.public.powerpoint
external usenet poster
 
Posts: 2
Default Excel to Powerpoint 2003 Chart Width

Hello All...

I built a tool designed to push All or Selected Charts and
ChartObjects directly to PowerPoint. The code below is for
ChartObjects and works great (charts are properly formatted within the
slide) in 2007 (Office12) but not in 2003. In 2003, the width of the
chart extends off the right slide of the slide. I added the debug
lines and modified the Width calc but in each case the width value is
off the slide - which is strange because the math is straightforward.
I recall some info about 2003 to 2007 Ppt changes but have not been
able to track them down. Thanks for any help...

-Robert

For Each chtobj In Sheets(n).ChartObjects
sld_count = sld_count + 1
chtobj.Copy
Set PPSlide = ppPres.Slides.Add(Index:=ppPres.Slides.Count + 1,
Layout:=ppLayoutBlank)
PPSlide.Select
'// Paste the chart/shape
PPSlide.Shapes.Paste
Set shp = PPSlide.Shapes(1)
With ppPres.PageSetup
shp.Left = frmPpt.TextBox1.Value * 75
shp.Top = shp.Left
'// SlideWidth does not calc as expected
shp.Width = .SlideWidth - (shp.Left * 2)
shp.Height = .SlideHeight - (shp.Top * 2)

Debug.Print "left: " & shp.Left
Debug.Print "top: " & shp.Top
Debug.Print "width: " & shp.Width
Debug.Print "height: " & shp.Height
Debug.Print "--------"
End With
'// Add TextBoxes
AddTextbox
Next
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Extracting chart title from Embedded Excel Chart in PowerPoint Barb Reinhardt Excel Programming 1 June 11th 08 02:22 PM
ASC() does not convert full-width to half-width letters (Exel 2003 DY Excel Worksheet Functions 0 January 27th 07 01:34 PM
excel chart to powerpoint k2sarah Excel Programming 1 February 22nd 06 10:25 PM
increase column width in PowerPoint chart PowerPoint Question Excel Discussion (Misc queries) 0 February 22nd 06 10:07 PM
Excel chart in Powerpoint Chris Charts and Charting in Excel 2 December 10th 04 01:19 PM


All times are GMT +1. The time now is 01:16 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"