Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
sagarkharpude
Creator III
Creator III

Unable to increase the Width of object while exporting object to ppt

Hi,

I am using the macro to export the object to ppt. But i am not able to increase the width of the object in macro. I am using the below code for top, width, height, etc.

ActiveDocument.GetSheetObject("TX150").CopyBitmapToClipboard ' Issue Description

with PPSlide.Shapes.PasteSpecial(3)

PPSlide.Shapes(PPSlide.Shapes.Count).Left = 10

PPSlide.Shapes(PPSlide.Shapes.Count).Top = 430

PPSlide.Shapes(PPSlide.Shapes.Count).width = 3

PPSlide.Shapes(PPSlide.Shapes.Count).height = 29

end with

Can someone please help me?

Thanks

10 Replies
tamilarasu
Champion
Champion

Hi Sagar,

ActiveDocument.GetSheetObject("TX150").CopyBitmapToClipboard ' Issue Description

Set objPPT = CreateObject("PowerPoint.Application")

objPPT.Visible = True

Set objPresentation  = objPPT.Presentations.Add


With PPSlide.Shapes.PasteSpecial(3)

   .Left = 10

   .Top = 430

   .Width = 3

   .Height = 29

End with

sagarkharpude
Creator III
Creator III
Author

Hi ,

It's not increasing the size of the text object.

Thanks

tamilarasu
Champion
Champion

Hi marcus_sommer


Do you know why the width syntax is not working properly.?


Thank you.

marcus_sommer

For me it worked - if the entries for width and height are in a certain relation to each other, for example 400 and 80 or 100 and 20 - otherwise these settings will be ignored. Maybe you could differ from these restrictions if some of the graphic-properties like the following are changed before setting the width:

- Marcus

sagarkharpude
Creator III
Creator III
Author

Hi Marcus,

In my system this settings are in inches instead of cm. After converting this inches to cms in qlikview still it's not working.

tamilarasu
Champion
Champion

Hi,

I have unchecked the "Lock Aspect Ratio" option through macro. Have a look at the attachment.

marcus_sommer

I think the unit from the numbers isn't important but the relation between width and height are. Did you try various combinations with the example from Tamil or only with your own application?

- Marcus

tamilarasu
Champion
Champion

Ahh. Now, I understood my mistake. I have modified the code like below.

Capture.PNG

Thanks for your clarification.

sagarkharpude
Creator III
Creator III
Author

I tried various combinations of height and width but it's difficult to set exact height and width.