I have a product database and would like to have up to three jpegs display for each product (each record). I am currently using Access Object Frames to display the jpegs from three text fields: Pic1, Pic2, and Pic3 (one for each possible picture). Some records may only display 1 or 2 pictures. In the case of just one picture, the text fields Pic2 and Pic3 are plank. The names of my controls are PICTURE1, PICTURE2, and PICTURE3. I am having the hardest time trying to get the images to display. Here is my current code:
When I move from record to record, I do not get any error messages. Can anyone help me?
Code:
Private Sub Form_Current()
'Code to link pictures
Dim strPath1 As String
Dim strPath2 As String
Dim strPath3 As String
On Error GoTo err_Current
strPath1 = Nz(Me.Pic1)
strPath2 = Nz(Me.Pic2)
strPath3 = Nz(Me.Pic3)
Me.PICTURE1 = strPath1
Me.PICTURE2 = strPath2
Me.PICTURE3 = strPath3
'End Code to link pictures
exit_Sub:
Exit Sub
err_Current:
MsgBox Err.Description
Resume exit_Sub
End Sub
When I move from record to record, I do not get any error messages. Can anyone help me?