Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Private Sub CL_Name_DblClick(Cancel As Integer)
MsgBox TableForField("CL_Name")
End Sub
Private Function TableForField(FieldName As String) As String
Dim fd As DAO.Field
With Me.Recordset
For Each fd In .Fields
If UCase(fd.Name) = UCase(FieldName) Then
If Len(fd.SourceTable & "") > 0 Then
TableForField = fd.SourceTable
Else
TableForField = "No Source Table"
End If
Exit For
End If
Next
End With
End Function
[red]Public[/red] Function TableForField(FieldName As String[red],rs As DAO.Recordset[/red]) As String
Dim fd As DAO.Field
With [red]rs[/red]
For Each fd In .Fields
If UCase(fd.Name) = UCase(FieldName) Then
If Len(fd.SourceTable & "") > 0 Then
TableForField = fd.SourceTable
Else
TableForField = "No Source Table"
End If
Exit For
End If
Next
End With
End Function
Private Sub SomeField_DblClick(Cancel As Integer)
MsgBox TableForField("SomeField"[red], Me.Recordset[/red])
End Sub