I have been trying to add a picture frame to a slide using the example provided on the documentation page. Below is what I have so far.
Dim myImageName As String
myImageName = Row(3) 'gets the picture file name
'Add the picture
Dim picid As Integer = pres.Pictures.Add(New Picture(pres, System.Configuration.ConfigurationSettings.AppSettings(“ImagePath”) & myImageName))
'add the picture frame and add the picture to the slide
Dim pf As PictureFrame = Slide.Shapes.AddPictureFrame(picid, 0, 0, 2000, 2000)
Everything seems to work down to the “Dim PF” statement above. I get an error when it runs stating the object has not been set. I am pretty sure I have not set the slide object correctly.
I have "Dim Slide as Slide"
I have not been able to figrue out what to make “Slide” equal to. If I remove the “Dim Slide as Slide” then I get a squigley line under “Slide.Shapes”. I must be missing something simple. Can you give me the proper settings.