Help with Macro to Find based on cell Change

largeselection

Active Member
Joined
Aug 4, 2008
Messages
358
Hi,

I've done a little bit with macros that run on changes within a cell (checkmarks and such).

I'm trying to have one that basically executes a find based on the cell value that changes. As it stands now I have a sheet conditionally formatted so that when I put in an ID number in cell B17 it will highlight the entire row where the value in B17 is equal to the value in the cell in column A.

What I'd ultimately like to have happen is for it to execute a find and "jump" to that location. So I'd like to be able to type in ID# 1 into B17 and then have it automatically jump to that row (which will be highlighted yellow).

Sorry if this is confusing please let me know if you have any questions! THANKS!
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
This should get you started, right click the ws tab and pate this code in;
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Cells.Find(What:=Range("B17").Value, After:=ActiveCell, LookIn:=xlFormulas).Activate
End Sub

Cheers
Colin
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,459
Messages
6,124,945
Members
449,198
Latest member
MhammadishaqKhan

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top