Mohamedazees
New Member
- Joined
- Oct 18, 2020
- Messages
- 43
- Office Version
- 2019
- Platform
- Windows
Dear Sir,
I need to apply target for multiple ranges in a same sheet refer the below code i have applied Target for Column "G" like wise I need to target Column N & T accordingly do VLOOKUP's like below with difference ranges
Thanks in advance
Code:
Option Explicit
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Intersect(Target, [G:G]) Is Nothing Or Target.Count > 1 Then Exit Sub
'Target.Offset(, -1) = Time
Target.Offset(, 1) = Application.VLookup(Target, Sheet10.Range("A:B"), 2, False)
End Sub
I need to apply target for multiple ranges in a same sheet refer the below code i have applied Target for Column "G" like wise I need to target Column N & T accordingly do VLOOKUP's like below with difference ranges
Thanks in advance
Code:
Option Explicit
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Intersect(Target, [G:G]) Is Nothing Or Target.Count > 1 Then Exit Sub
'Target.Offset(, -1) = Time
Target.Offset(, 1) = Application.VLookup(Target, Sheet10.Range("A:B"), 2, False)
End Sub