alonso9122
New Member
- Joined
- Aug 10, 2018
- Messages
- 3
Dear Community,
On the last days I have tried to develop the following:
I have a PPT presentation with a specific amount of slides. Starting from the second slide I have pasted excel tables directly linked to the file (paste special). Sometimes I have been facing the issue that after updating the links when I open the PPT presentation, the tables appear with a different size and position.
To get rid of this, I would like to have a macro that allows me to resize and reposition all these charts to the desired values.
I found the following resizing/repositioning part:
Sub Adjustment()
With ActiveWindow.Selection.ShapeRange
.LockAspectRatio = msoFalse
.Height = 168
.Width = 992
.Left = 39
.Top = 157
End With
End Sub
It works well but as you realize it only works after clicking the specific chart and then running the macro.
My ideal would be:
1. Loops through each slide (starting from the second to the end)
2. On each slide, selects this only shape/chart (as on each slide I also have some boxes, aside from the excel table) and applies those same properties
I tried my best but hit a wall. I would really appreciate your support!
Thank you very much in advance!
On the last days I have tried to develop the following:
I have a PPT presentation with a specific amount of slides. Starting from the second slide I have pasted excel tables directly linked to the file (paste special). Sometimes I have been facing the issue that after updating the links when I open the PPT presentation, the tables appear with a different size and position.
To get rid of this, I would like to have a macro that allows me to resize and reposition all these charts to the desired values.
I found the following resizing/repositioning part:
Sub Adjustment()
With ActiveWindow.Selection.ShapeRange
.LockAspectRatio = msoFalse
.Height = 168
.Width = 992
.Left = 39
.Top = 157
End With
End Sub
It works well but as you realize it only works after clicking the specific chart and then running the macro.
My ideal would be:
1. Loops through each slide (starting from the second to the end)
2. On each slide, selects this only shape/chart (as on each slide I also have some boxes, aside from the excel table) and applies those same properties
I tried my best but hit a wall. I would really appreciate your support!
Thank you very much in advance!