Hello,
I'm trying to narrow down a list of 16,000 parts. unfortunately this list has been built up over several years and there has been no standard set as to what is in each column, I need to search through each cell and look for the letters "ABB" these are probably not the only thing in the cell so that pretty much puts me out of my area of knowledge.
Not only do I need to find these cells, I need to mark that row so I can run a different macro afterwards, either with an additional row or maybe a set colour (Anything excel and read to make it stand out from rows that don't have "ABB" somewhere in it.
I've copied a code I've found that looks to be doing something similar, I'm just curious as from what it seems, it only works for when there is just the one result as it contains no loops or anything that would make it seem to apply to multiple cells, but this could be just me misreading.
I'm certain I'll need to change this, firstly from how I'm reading this, it is just looking at "Column 2" I'll need mine to look at all off them. Also as said above I don't think this would work for when there are more than one result, could anyone suggest a way of looping it.
As you can see from the bits of the code that make about as much sense as a bra for snakes, I've tried to adapt it myself to see if I can get it to work but I just can't seem to find a way for it to do a "Find All" function or a way of looping it.
I'm pretty much blind with this area of code so any insight would be a huge help.
Best regards,
I'm trying to narrow down a list of 16,000 parts. unfortunately this list has been built up over several years and there has been no standard set as to what is in each column, I need to search through each cell and look for the letters "ABB" these are probably not the only thing in the cell so that pretty much puts me out of my area of knowledge.
Not only do I need to find these cells, I need to mark that row so I can run a different macro afterwards, either with an additional row or maybe a set colour (Anything excel and read to make it stand out from rows that don't have "ABB" somewhere in it.
I've copied a code I've found that looks to be doing something similar, I'm just curious as from what it seems, it only works for when there is just the one result as it contains no loops or anything that would make it seem to apply to multiple cells, but this could be just me misreading.
Code:
Sub Sample()
Dim ws As Worksheet
Dim aCell As Range
Dim X As Integer
Set ws = ThisWorkbook.Sheets("Partnumber")
With ws Set aCell = .Columns(2).Find(What:="ABB", LookIn:=xlValues, _
LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
MatchCase:=False, SearchFormat:=False)
If Not aCell Is Nothing Then
X = aCell.Row
Range("I" & X).Formula = "1"
Else
End If
End With
End Sub
I'm certain I'll need to change this, firstly from how I'm reading this, it is just looking at "Column 2" I'll need mine to look at all off them. Also as said above I don't think this would work for when there are more than one result, could anyone suggest a way of looping it.
As you can see from the bits of the code that make about as much sense as a bra for snakes, I've tried to adapt it myself to see if I can get it to work but I just can't seem to find a way for it to do a "Find All" function or a way of looping it.
I'm pretty much blind with this area of code so any insight would be a huge help.
Best regards,