You can paste it as written with a couple of minor tweaks to match your database
First of all, note that I've just added a missing code line -
Dim strFilePath As String
As stated in the code modify the line below to match the default location for your image files
- F.InitialFileName = Nz(Application.CurrentProject.path & "\ImageFiles\", "C:\")
As written, this will open the browse window to a subfolder ImageFiles in the location of your database ...if the folder exists... and if it doesn't exist, it will open to the root folder C:\
The selected file path will be displayed in a textbox called ImagePath. If your textbox has another name, modify the line below
- Me.ImagePath = strFilePath 'add the file path to a textbox on the form
Strongly recommend you do a basic course in simple coding e.g. the free videos by Steve Bishop on You Tube are an excellent starting point