B
Brad
I would like to add a button on my form that will open the save dialog box
and allow a user to select a picture from any location then it will save the
photo to a directory I specified and put a link to the picture in the table
that the form is linked to. The code to do this is fairly simple in excel but
I'm not sure how it translates to access. This is the code I would use in
excel, is there an equivalent in access?
Dim picFileName As String ' User selected location of picture file
Dim destFile As String ' Destination location to copy user selected picture
to
Dim num As String ' Issue_num (used as unique identifier for each photo)
destFile = "C:\Pictures." & num & ".jpg"
picFileName = Application.GetSaveAsFilename
'==They have cancelled.
If picFileName = "False" Then Exit Sub
'==Save the picture
FileCopy picFileName, destFile
I would like to use the record number as my num variable and place the
destFile in the corresponding field in my table. Thanks in advance for any
direction/help with this.
and allow a user to select a picture from any location then it will save the
photo to a directory I specified and put a link to the picture in the table
that the form is linked to. The code to do this is fairly simple in excel but
I'm not sure how it translates to access. This is the code I would use in
excel, is there an equivalent in access?
Dim picFileName As String ' User selected location of picture file
Dim destFile As String ' Destination location to copy user selected picture
to
Dim num As String ' Issue_num (used as unique identifier for each photo)
destFile = "C:\Pictures." & num & ".jpg"
picFileName = Application.GetSaveAsFilename
'==They have cancelled.
If picFileName = "False" Then Exit Sub
'==Save the picture
FileCopy picFileName, destFile
I would like to use the record number as my num variable and place the
destFile in the corresponding field in my table. Thanks in advance for any
direction/help with this.