![]() |
#1
|
|||
|
|||
![]()
I have 2007, in 2003 I could record a macro, but in 2007 ppt I cannot seem to find the control to record a macro?
The below macro worked in 2003, but does not work in 2007, its a simple fit to page function: ActiveWindow.Selection.ShapeRange.ScaleWidth 1, msoFalse, msoScaleFromBottomRight ActiveWindow.Selection.ShapeRange.ScaleHeight 1, msoFalse, msoScaleFromBottomRight ActiveWindow.Selection.ShapeRange.ScaleWidth 1, msoFalse, msoScaleFromTopLeft ActiveWindow.Selection.ShapeRange.ScaleHeight 1, msoFalse, msoScaleFromTopLeft End Sub |
#2
|
|||
|
|||
![]()
In PPT 2007 you can't record macro :-(
What about this code Code:
Dim shp As ShapeRange If ActiveWindow.Selection.Type = ppSelectionShapes Then Set shp = ActiveWindow.Selection.ShapeRange shp.Left = 0 shp.Top = 0 shp.Height = ActivePresentation.PageSetup.SlideHeight shp.Width = ActivePresentation.PageSetup.SlideWidth End If Set shp = Nothing |
#3
|
|||
|
|||
![]()
I get a comile error and it highlights the word activewindow in the macro
|
#4
|
|||
|
|||
![]()
I have office 2007 Powerpoint now and I cannot figure out a macro to fit a screen shot to an outline on the PPT I have created, it must fit within this outline, each ppt file is 7 pages and I have 300 files to create, I used to record a macro, but Microsoft decided to omit the record macro from office 2007, way to go Billy!, we are going backwards now???? Anyway ok I feel better, ok no I dont, is there anyone that can write my macro I recorded in 2003 for 2007???
Is this the best sight to ask questions like this, if anyone knows the best place let me know, have no idea? |
#5
|
|||
|
|||
![]()
Does anyone know of a real Powerpoint site where there is actually someone assisting users for the Pathetic PPT 2007 version????
|
#6
|
|||
|
|||
![]()
Does this work??
Dim oshp As Shape Dim osld As Slide Set osld = ActiveWindow.View.Slide Set oshp = osld.Shapes(osld.Shapes.Count) oshp.Left = 0 oshp.Top = 0 oshp.Height = ActivePresentation.PageSetup.SlideHeight oshp.Width = ActivePresentation.PageSetup.SlideWidth Set oshp = Nothing Set osld = Nothing |
#7
|
|||
|
|||
![]()
This fits to the entire ppt page, I have an outline on the ppt page that I need it to fit, I have attached the ppt file with the page outline.
Can you make the code have it fit within the outline? Also in 2003 my code fit to all pages in the file as all slides were the same, the code you provided requires residing on each page... can you make it fit all pages in the ppt file when open? |
#8
|
|||
|
|||
![]()
See if this gets you closer:
Code:
Sub FittopageCurrent() 'Fits the last added shape to the box on the master 'on current slide Dim oshp As Shape Dim osld As Slide Dim otarget As Shape Set otarget = ActivePresentation.SlideMaster.Shapes("Rectangle 8") Set osld = ActiveWindow.View.Slide Set oshp = osld.Shapes(osld.Shapes.Count) oshp.Left = otarget.Left oshp.Top = otarget.Top oshp.LockAspectRatio = False oshp.Height = otarget.Height oshp.Width = otarget.Width Set oshp = Nothing Set osld = Nothing End Sub Sub FittopageAll() 'Fits the last added shape to the box on the master 'on all slides Dim oshp As Shape Dim osld As Slide Dim otarget As Shape Set otarget = ActivePresentation.SlideMaster.Shapes("Rectangle 8") For Each osld In ActivePresentation.Slides If osld.Shapes.Count > 0 Then Set oshp = osld.Shapes(osld.Shapes.Count) oshp.Left = otarget.Left oshp.Top = otarget.Top oshp.LockAspectRatio = False oshp.Height = otarget.Height oshp.Width = otarget.Width End If Next osld Set oshp = Nothing Set osld = Nothing End Sub |
#9
|
|||
|
|||
![]()
Perfection, thanks much.....
|
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
VBA: Recording a macro to insert a PIVOT table | e093223 | Excel Programming | 0 | 10-09-2011 01:55 AM |
Recording Macro Tutorials | JesseAitchison | Word VBA | 0 | 07-24-2011 05:36 PM |
Recording Macros Tutorial? | Madhouse | Word VBA | 1 | 04-28-2010 01:32 PM |
Tutorial recording macros | Jaffa | Word VBA | 0 | 04-27-2010 09:14 PM |
Sound Recording | stilts77 | PowerPoint | 0 | 03-13-2010 03:25 AM |