H
Hammy
Guest
Trying to insert an image into a report that changes from record to record according to a path in a table.
Acorrding to MS Access help files
However, I must be blind, because Reports have no On Current event. Even accroding to MS help files again, On Current only applies to Form Object.
I even tried changing the Sub by placing Report in for Form as their "note" says......nothing.
So what does a guy do???
Thanks,
Hammy
Acorrding to MS Access help files
Double-click the form selector or the report selector to open the property sheet.
Click the Build button next to the OnCurrent property box, and then click Code Builder in the Choose Builder dialog box.
Create the following event procedure. Substitute the name of the image control on your form or report for ImageControlName and the name of the control containing the path for ImagePath.
Private Sub Form_Current()
On Error Resume Next
Me![ImageControlName].Picture = Me![ImagePath]
End Sub
Note that if you are adding the event procedure in a report, the first line of the procedure will be the following:
Private Sub Report_Current()
However, I must be blind, because Reports have no On Current event. Even accroding to MS help files again, On Current only applies to Form Object.
I even tried changing the Sub by placing Report in for Form as their "note" says......nothing.
So what does a guy do???
Thanks,
Hammy