B
Bradley C. Hammerstrom
Access200 DAO
I'm still working on this. Whether a form is loaded or closed, view the same
record. I got the DoCmd.OpenForm part to work.
Now, how do I GoTo the same record in another loaded form?
***********************
Private Sub cmdGoToMain_Click()
Dim strFormName As String
Dim intRecNumber As Integer
Dim strPhotoRecord As String
strFormName = "frmMain"
intRecNumber = Me.Bookmark '(Type Mismatch)
strPhotoRecord = Me.PhotoID
If IsLoaded(strFormName) Then
'Go to same photo
DoCmd.GoToRecord acDataForm, strFormName, acGoTo, intRecNumber
Else
'Open the PhotoBook form and go to same photo
DoCmd.OpenForm strFormName, , , OpenArgs:=strPhotoRecord
End If
End Sub
*************************
Bookmark is a string. I need a number for the offset argument that is
acCurrent.
Very confused.
Brad H.
I'm still working on this. Whether a form is loaded or closed, view the same
record. I got the DoCmd.OpenForm part to work.
Now, how do I GoTo the same record in another loaded form?
***********************
Private Sub cmdGoToMain_Click()
Dim strFormName As String
Dim intRecNumber As Integer
Dim strPhotoRecord As String
strFormName = "frmMain"
intRecNumber = Me.Bookmark '(Type Mismatch)
strPhotoRecord = Me.PhotoID
If IsLoaded(strFormName) Then
'Go to same photo
DoCmd.GoToRecord acDataForm, strFormName, acGoTo, intRecNumber
Else
'Open the PhotoBook form and go to same photo
DoCmd.OpenForm strFormName, , , OpenArgs:=strPhotoRecord
End If
End Sub
*************************
Bookmark is a string. I need a number for the offset argument that is
acCurrent.
Very confused.
Brad H.