Consulting

Results 1 to 20 of 20

Thread: vba selective copying and pasting on the same powerpoint slide

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #11
    VBAX Tutor
    Joined
    Jun 2012
    Posts
    264
    Location

    vba Selective Copying and Pasting Shapes on the Same PowerPoint Slide

    vba Selective Copying and Pasting Shapes on the Same PowerPoint SlideFor Clarity: After you clicked on a shape (and hence select it), it should be replicated down, just below the shape selected, but to the left, i.e. just below the first shape in the "line".
    The macro must be started after the click, or double-click (preferably if possible).
    The next shape will be in line, horizontally to the right of the previous copy and pasted shape.
    The next step is to repeat the new pattern below this line.
    See attached file for clarity - The first slide shows how it looks before doing anything and the second the final result.


    I found the following working code from PPTools and tried to modify it for my purpose. The third slide of the attached file shows how it is used. If it can be adapted for copying and pasting or duplicating shapes it would be perfect:

    Sub DoItToMe(oShape As Shape)
    With oShape
        ' Add code here to do whatever you like with the shape
        ' This will make it unfilled if filled or vice versa
        .Fill.Visible = Not (.Fill.Visible)
    End With
    End Sub

    Any help will be highly appreciated

    Best Regards
    Vanhunk
    Attached Files Attached Files
    Last edited by Aussiebear; 05-09-2025 at 01:46 PM. Reason: Fixed the code tags and reduced the font size

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •