If you have a moment, please take a look at this and tell me how you would indent it. I'm forming a whole new standard, thougt it was perfect time to entertain some new ideas.
Happy New Year Y'all.
Happy New Year Y'all.
Code:
Private Sub Form_Click()
Me.txtHighlight.Requery
Dim Rs As DAO.Recordset
Dim ctl As Control
Dim varItem As Variant
pubProjectID = Me.txtSourceID
pubEntityID = pubProjectID
pubEntityTableID = 3
Me.Parent.lstFileType.RowSource = "qryFileTypeGroup"
Call SelectAll(Forms!frmProjectManagement.lstFileType)
strSQL = "DELETE tblLocalFilter.rfReportFilterID " & vbCrLf & _
"FROM tblLocalFilter;"
CurrentDb.Execute strSQL, dbFailOnError
Set Rs = CurrentDb.OpenRecordset("tblLocalFilter")
If Me.Parent.lstFileType.ItemsSelected.Count = 0 Then
Me.Parent.lstFileType.Requery
Me.Parent.frmActionItemAttachmentsSubform.Requery
Exit Sub
End If
Set ctl = Me.Parent.lstFileType
For Each varItem In ctl.ItemsSelected
Rs.AddNew
Rs!lfFileTypeID = ctl.ItemData(varItem)
Debug.Print ctl.ItemData(varItem)
Rs.Update
Next varItem
Set Rs = Nothing
Me.Parent.frmActionItemAttachmentsSubform.Requery
End Sub