Adding Picture to Powerpoint via

Hi all,

i need to add a picture or pictures specific places existing ppt but i do not know how can i do that

anyone can help me via

NOT : I cannot use activities.
NOT : Location and size can manageable

Thank you.

Hello @Kuki_Force ,

Please try this:

Public Sub AddImageToPage(doc As PPTXDocument, logoPath As [String], x As Single, y As Single)
	Dim img As New REImage(logoPath)
	For i As Integer = 0 To doc.GetPageCount() - 1
		Dim tmp As PPTXPage = DirectCast(doc.GetPage(i), PPTXPage)
		' Add REImage to the PPTXPage and embed it in the form of Jpeg.
		tmp.AddImage(img, x, y, PPTUnits.[Default], ImageFormat.Jpeg)
End Sub


Hope it helps!
Best regards,

1 Like


thanks for response. I forget the mention that i’m going to use vb. net in invoke code :slight_smile:

This code can work directly or need to change some places?

Thank you.

@Kuki_Force ,

Instead of declaring variables, within our invoke code activity, we should use arguments

Please check this topic (and it’s example) for a better understanding:

Hope it helps!
Best regards,