SockMonkey
IS-IT--Management
Here is a tricky issue I have been trying to overcome.
I am using field labels at the top of a continuous form to sort the records in the form.
Private Sub LabelName_OnClick()
Sort "fieldName"
End Sub
Private Sub LabelName_OnDoubleClick()
Sort "fieldName", " DESC"
End Sub
If have the sub
Private Sub Sort(fldName As String, Optional SortOrd As String)
Me.OrderBy = ""
Me.OrderBy = fldName & SortOrd
Me.OrderByOn = True
End Sub
The issue is that I would like to get the corresponding field name automatically from the labels tag when the even OnClick for that label is run.
so in essence the procedure would look like this:
Private Sub LabelName_OnClick()
Dim strFieldName as String
strFieldName Me.acLabel.tag
Sort strFieldName
End Sub
However, we all know that you can not get the labels tag value in this method.
Bottom line, how can I get that value?
Thanks in advance for any suggestions.
I am using field labels at the top of a continuous form to sort the records in the form.
Private Sub LabelName_OnClick()
Sort "fieldName"
End Sub
Private Sub LabelName_OnDoubleClick()
Sort "fieldName", " DESC"
End Sub
If have the sub
Private Sub Sort(fldName As String, Optional SortOrd As String)
Me.OrderBy = ""
Me.OrderBy = fldName & SortOrd
Me.OrderByOn = True
End Sub
The issue is that I would like to get the corresponding field name automatically from the labels tag when the even OnClick for that label is run.
so in essence the procedure would look like this:
Private Sub LabelName_OnClick()
Dim strFieldName as String
strFieldName Me.acLabel.tag
Sort strFieldName
End Sub
However, we all know that you can not get the labels tag value in this method.
Bottom line, how can I get that value?
Thanks in advance for any suggestions.