Hello Everyone,
I used the script below in my form to show an unbound image sourced from a directory in drive C:\, which worked well!
Now, Im hoping to figure out how can I do the same thing in the report...Show the unbound image....
Here's the Script used in the report. Please check what Ive missed or in error...
Private Sub Report_Open(Cancel As Integer)
On Error GoTo errhandler
Dim y As Integer
Dim directory As String
Dim extension As String
directory = "d:\picture\"
extension = ".jpg"
Me.image1.Picture = directory & Me.empid & extension
errhandler:
If Err = 6 Then
Me.image1.Picture = "d:\picture\nopicture.jpg"
End If
Resume Next
End Sub
Thanks
Francis
I used the script below in my form to show an unbound image sourced from a directory in drive C:\, which worked well!
Now, Im hoping to figure out how can I do the same thing in the report...Show the unbound image....
Here's the Script used in the report. Please check what Ive missed or in error...
Private Sub Report_Open(Cancel As Integer)
On Error GoTo errhandler
Dim y As Integer
Dim directory As String
Dim extension As String
directory = "d:\picture\"
extension = ".jpg"
Me.image1.Picture = directory & Me.empid & extension
errhandler:
If Err = 6 Then
Me.image1.Picture = "d:\picture\nopicture.jpg"
End If
Resume Next
End Sub
Thanks
Francis