G
Guest
I'm using the following code to display images on a form. It works fine.
However, If you scroll to fast through the records, access crashes. How can
I prevent this from happening?
Thanks.
Function setImagePath()
Dim strImagePath As String
On Error GoTo PictureNotAvailable
strImagePath = Me.txtImageName
Me.ImageFrame.Picture = strImagePath
Exit Function
PictureNotAvailable:
strImagePath = "\\server\newparts\npimages\np.jpg"
Me.ImageFrame.Picture = strImagePath
End Function
However, If you scroll to fast through the records, access crashes. How can
I prevent this from happening?
Thanks.
Function setImagePath()
Dim strImagePath As String
On Error GoTo PictureNotAvailable
strImagePath = Me.txtImageName
Me.ImageFrame.Picture = strImagePath
Exit Function
PictureNotAvailable:
strImagePath = "\\server\newparts\npimages\np.jpg"
Me.ImageFrame.Picture = strImagePath
End Function