I want to be able to look up a cell in excel then go to another c.

J

Jason Morin

Something has to trigger Excel to evaluate G10=G160 and
then select J160 if it is TRUE. What will trigger it? One
possibility is a Worksheet_Change event so that if cells
G10 or G160 are changed by the user, the macro will fire.

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, Range("G10,G160")) _
Is Nothing Then
If Me.[G10].Value = [G160].Value Then
Me.[J160].Select
End If
End If
End Sub


---
To use, right-click on the worksheet tab and choose "View
Code". Paste in the code above and press ALT+Q to close
VBE.

HTH
Jason
Atlanta, GA
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top