thomassoler
New member
- Local time
- Tomorrow, 05:14
- Joined
- Feb 20, 2019
- Messages
- 3
Hi! I am trying to create a subject module where the main single photo of the person will be in the form named as SubjectPhoto while in the subform there are additional photos namely: SubjectPhoto1, 2, 3 & 4. I have successfully done it with SubjectPhoto and SubjectPhoto1. The code in the current however I am having difficulty to add SubjectPhoto2, 3 & 4. Would appreciate any help. Code below:
Option Compare Database
Private Sub Form_Current()
If Me.SubjectPicture.Value <> "" Then
If fFileExists(Me.SubjectPicture.Value) Then
Me.imgSubjectPicture.Picture = Me.SubjectPicture.Value
Else
Me.imgSubjectPicture.Picture = ""
End If
Else
Me.imgSubjectPicture.Picture = ""
End If
End Sub
Private Sub imgSubjectPicture_Click()
Dim strPicture As String
strPicture = GetOpenFile(, "Select a picture...", , True)
If strPicture <> "" Then
Me.imgSubjectPicture.Picture = strPicture
Me.SubjectPicture.Value = strPicture
Else
Me.imgSubjectPicture.Picture = ""
Me.SubjectPicture.Value = ""
End If
End Sub
Private Sub imgSubjectPicture_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
MouseCursor IDC_HAND
End Sub
Option Compare Database
Private Sub Form_Current()
If Me.SubjectPicture.Value <> "" Then
If fFileExists(Me.SubjectPicture.Value) Then
Me.imgSubjectPicture.Picture = Me.SubjectPicture.Value
Else
Me.imgSubjectPicture.Picture = ""
End If
Else
Me.imgSubjectPicture.Picture = ""
End If
End Sub
Private Sub imgSubjectPicture_Click()
Dim strPicture As String
strPicture = GetOpenFile(, "Select a picture...", , True)
If strPicture <> "" Then
Me.imgSubjectPicture.Picture = strPicture
Me.SubjectPicture.Value = strPicture
Else
Me.imgSubjectPicture.Picture = ""
Me.SubjectPicture.Value = ""
End If
End Sub
Private Sub imgSubjectPicture_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
MouseCursor IDC_HAND
End Sub