I restored the code to original. I removed the code I was using (selection.copy) to get the photo to the clip board and copied a photo manually (Ctrl-C). When running the new code I did not get an error but neither was the photo put into the image control. Here's my code:
Private Sub Vio1ChoosePhoto1_Click()
Dim myFiles As String
ChDir "C:\$0Temp"
myFiles = Application.GetOpenFilename(, , , , False)
If myFiles = "" Then Exit Sub
Worksheets("Photos").Activate
ActiveSheet.Pictures.Insert(myFiles).Select
Selection.Copy
With Violations1.Image1
.Picture = PastePicture(xlPicture)
.PictureSizeMode = fmPictureSizeModeZoom
End With
End Sub
Probably not to elegant.
Bookmarks