Shapes.AddPicture
Creates a picture from an existing file. It returns a Shape object that represents the new picture. You can read more about it in Shapes.AddPicture Method
Change the line
If delshape.Type = msoAutoShape Then delshape.Delete
to
If delshape.Type = msoPicture Then delshape.Delete