Dan,
Create a table , call it tblImages
Three fields;
1) ImagesID (AutoNumber) PK
2) ImagePathName ' This hold the path and name of your image e.g
C:\AccessImages\Dog1.jpg
3) ImageDescription ' This is a simple description of your image e.g Me Dog
Fill the table with 2 or 3 lots of data
Make a form using the Form Wizard, Select Columnar (it is the default)
In Default View add Image Frame using Toolbox , when it wants you to select
an image use anything on the hard disk.
For this exercise change the image frame name to Image7
Change Picture type from embedded to linked
Change Size Mode to Zoom
Now copy the code below to the On Current of the form. (Douglas is correct,
you must use the On Current Event of your form.)
After you have copied the code, go back to the Image frame and delete the
path in your Picture ( this is the one that the image required when you
first started to insert the image frame) and replace it with this (none) yes
you use the ( ).
Save your form, open it and enjoy.
Regards,
John A
===============CODE=====================STARTS HERE=========================
Dim strNoPic As String
strNoPic = "C:\AccessImages\NP.jpg" ' This is a path of a picture to use
when you are on a new record, Mine is a ? from clip art.
If Me.NewRecord = True Then
Me.Image7.Picture = strNoPic 'When it is a new record then the
default will display
Else
Me.Image7.Picture = Me.ImagePathName ' This is the name of the bound
text box on your form.
End If
===============CODE=====================ENDS HERE=========================