View Single Post
 
Old 12-19-2017, 01:20 PM
NoSparks NoSparks is offline Windows 7 64bit Office 2010 64bit
Excel Hobbyist
 
Join Date: Nov 2013
Location: British Columbia, Canada
Posts: 842
NoSparks is a glorious beacon of lightNoSparks is a glorious beacon of lightNoSparks is a glorious beacon of lightNoSparks is a glorious beacon of lightNoSparks is a glorious beacon of light
Default

Quote:
My research so far has led me to believe that I would need to put this code in each of the 24 worksheets.
Sounds like you could use the Workbook_SheetChange event in the ThisWorkbook module.
Attaching a sample workbook to work with would be advantages.
Without knowing how your 24 sheets are associated with the correct table on the main worksheet can't elaborate much,
would think you could use something along the lines of this...

Code:
Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
    'don't apply to Main sheet
    If Sh.Name = "Main" Then Exit Sub
    'limit to single cell in column K
    If Target.Count > 1 Or Target.Column <> 11 Then Exit Sub

    Dim ray As Variant
    Dim oLo As ListObject, nxtRow As ListRow

If UCase(Target.Value) = "NO" Then
    ray = Split(Cells(Target.Row, "B").Value & "|" & Cells(Target.Row, "D").Value & "|" & Cells(Target.Row, "J").Value, "|")
    With Sheets("Main")
        Set oLo = .ListObjects("?")  'don't know how you associate table to sheet
        Application.EnableEvents = False
        Set nxtRow = oLo.ListRows.Add
        nxtRow.Range.Cells(1, 2).Resize(, 3).Value = ray
        Application.EnableEvents = True
    End With
End If

End Sub
Here's a couple of links to sites dealing with tables
https://www.thespreadsheetguru.com/b...t-excel-tables
http://www.jkp-ads.com/Articles/Exce...lComments=True
Reply With Quote