Hi all,
I'll outline the details of my set up in dot point form:-
I have the following VBA code on the "notes" sheet:-
I cannot for the life of me get it working. I have tried fiddling with bits and pieces, but it just gives me different vba errors.
Any help would be greatly appreciated, as I'm relatively new at creating my own code from scratch. Normally I just modify other people's work to suit, but couldn't find any examples similar to what I require...
Cheers!
I'll outline the details of my set up in dot point form:-
- I have a sheet called "IAR"
- It has a table also called "IAR"
- I have a named range on this sheet called "IARcol" which references the formula "=IAR[[#All],[Job No]]"
- I have another sheet called "notes"
- It has a table called "notes"
- I have a named range on the sheet called "NotesExpectedDate" which references "=Notes[[#All],[NewExpectedDate]]"
I have the following VBA code on the "notes" sheet:-
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Dim SearchCell As Range
Dim IARcolumn As Range
Set IARcolumn = Sheets("IAR").Range("IARcol")
Set SearchCell = Sheets("IAR").IARcolumn.Find(What:=Left(Target.Offset(0, -5), 6).Value, After:=ActiveCell, LookIn:=xlValues, LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:=False, SearchFormat:=False)
If Not Intersect(Target, Range("NotesExpectedDate")) Is Nothing Then
SearchCell.Offset(0, 23).Value = Target.Value
End If
End Sub
I cannot for the life of me get it working. I have tried fiddling with bits and pieces, but it just gives me different vba errors.
Any help would be greatly appreciated, as I'm relatively new at creating my own code from scratch. Normally I just modify other people's work to suit, but couldn't find any examples similar to what I require...
Cheers!