I would like to ask about displaying photos in MS Access form.
I have a column where are paths to specified images like: "M:\Staz\Access\Zdjecia\window.png" etc. But I am wondering what if the field with the path is wrong or the file doesn't exist...? Have You any other ideas in which way I can check this exceptions...? In example display the messages if wrong file path or no photo...
Now I have the exception for the empty field:
Code:
Private Sub Form_Current()
Dim No_photo As String
No_photo = "M:\Staz\Access\Zdjecia\error.jpg"
If IsNull(Me.Photo) Then
imgPart.Picture = No_photo
Else
On Error Resume Next ' for wrong path or no file in there
imgPart.Picture = Me.Photo
End If
End Sub