Excel VBA Macro to Copy Excel Range to PowerPoint Slide with Source Formatting as Editable Table
If we want to copy the Excel Range as a Editable Table Format to Power Point Slide , we need to use the " CommandBars.ExecuteMso ("PasteSourceFormatting") " method.
Sample Code :
Dim New_PPT As PowerPoint.Presentation
Dim PPT_Slide As PowerPoint.Slide
Set New_PowerPoint = New PowerPoint.Application
New_PowerPoint.Visible = msoCTrue
New_PowerPoint.ActiveWindow.View.GotoSlide (PPT_No)
Set PPT_Slide = New_PowerPoint.ActivePresentation.Slides(PPT_No)
MyRange.Copy
New_PowerPoint.Activate
PPT_Slide.Select
PPT_Slide.Application.CommandBars.ExecuteMso ("PasteSourceFormatting")
Thanks ,TAMATAM
If we want to copy the Excel Range as a Editable Table Format to Power Point Slide , we need to use the " CommandBars.ExecuteMso ("PasteSourceFormatting") " method.
Sample Code :
Dim New_PPT As PowerPoint.Presentation
Dim PPT_Slide As PowerPoint.Slide
Set New_PowerPoint = New PowerPoint.Application
New_PowerPoint.Visible = msoCTrue
New_PowerPoint.ActiveWindow.View.GotoSlide (PPT_No)
Set PPT_Slide = New_PowerPoint.ActivePresentation.Slides(PPT_No)
MyRange.Copy
New_PowerPoint.Activate
PPT_Slide.Select
PPT_Slide.Application.CommandBars.ExecuteMso ("PasteSourceFormatting")
Thanks ,TAMATAM
No comments:
Post a Comment
Hi User, Thank You for visiting My Blog. Please post your genuine Feedback or comments only related to this Blog Posts. Please do not post any Spam comments or Advertising kind of comments which will be Ignored.