Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Community
I got the following macro but it will only export the active sheet and also the image got truncated.
sub exportppt
Set objPPT = CreateObject("PowerPoint.Application")
objPPT.Visible = True
Set objPresentation = objPPT.Presentations.Add
Set PPSlide = objPresentation.Slides.Add(1,11)
ActiveDocument.ActiveSheet.CopyBitmapToClipboard
PPSlide.Shapes.Paste
Set PPSlide = Nothing
Set PPPres = Nothing
Set PPApp = Nothing
End Sub
How can i export all the sheets in the application into different slides without the image being truncated?
I did what as you told but i still can't get a full image.
Yes but it's seem like even i have fit the zoom to window and then export, i still can't output the full image.
Can you possibly provide the most current demo files you're testing with?
As attached and i reattached the ppt as well.
Hi Surynn,
Please use array:
Sub Export_ppt
Dim myArray(2)
myArray(0) = "LB04"
myArray(1) = "LB06"
myArray(2) = "CH02"
Set objPPT = CreateObject("PowerPoint.Application")
objPPT.Visible = True
Set objPresentation = objPPT.Presentations.Add
For count = 0 to ubound(MyArray)
Set PPSlide = objPresentation.Slides.Add(1,11)
ActiveDocument.GetSheetObject(MyArray(count)).CopyBitmapToClipboard
PPSlide.Shapes.Paste
Next
Set PPSlide = Nothing
Set PPPres = Nothing
Set PPApp = Nothing
End Sub
There are two drop-down fields on the left side from macro-editor - the settings must be system access.
Weird.
I do get a complete picture in every powerpoint sheet. See attachment.
Is your desktop set at 100% scaling?
Yes at 100% scaling. You didn't get a complete pic for the last sheet, the last sheet is a bit longer.
Thanks Nitha for your response. But i want export the whole sheet instead of a few objects.
The issue doesn't appear to be with the sizing of the sheet in the window view rather the overall size of the qlikview window. I tested removing the tabrow as well as disabled any toolbars to get "more" on the screen and in fact, there was more in the image exported to ppt.
So that, in part, clarifies where the problem is.......now the question is how to resolve it....of course you could always call the windows script and execute a printscreen image to copy...but that would result in seeing the application pieces in the image as well which I imagine is not desired.
You mean the bigger the screen or the higher the screen resolution, the more image i got? So if it want get a complete image of the application, my application window size must smaller than my screen? Call the windows script and execute a printscreen image to copy is the only way out?