Hope you can help.
I have extracted the below code from a Macro in an old workbook, but need to adapt it to another sheet
In my new sheet I am populating data in D24.
In D25, I want it to auto populate a tier the work is categorised into
Below is an extract, hopefully this will be enough to give you the idea of what I need (In the original sheet there was a Column Header called "Changes Requested", but I cannot work out how to adapt to look at a particular cell, rather than that column header, then the details in that row.
So, if the value was 20x Attribute removal in D24, then in D25 I want it to Say
I have extracted the below code from a Macro in an old workbook, but need to adapt it to another sheet
In my new sheet I am populating data in D24.
In D25, I want it to auto populate a tier the work is categorised into
Below is an extract, hopefully this will be enough to give you the idea of what I need (In the original sheet there was a Column Header called "Changes Requested", but I cannot work out how to adapt to look at a particular cell, rather than that column header, then the details in that row.
VBA Code:
If varChangesRequested Like "*ssignment*" Then
currTier = 3
ElseIf varChangesRequested Like "*ttribute removal*" Or _
varChangesRequested Like "*LOV value removal*" Then
currTier = 2
'Business rule changes
ElseIf varChangesRequested Like "*Business rule changes*" Then
If dChangesRequested.Item(varChangesRequested) > 30 Then
currTier = 2
Else
currTier = 1
End If
Next
'update the field on the tracker
Select Case maxTier
Case 0
ThisWorksheet.Cells(CurrentCell.Row, FindColumn(ThisWorksheet, "Tier").Column).Value = "Unable to calculate Tier"
Case 1
ThisWorksheet.Cells(CurrentCell.Row, FindColumn(ThisWorksheet, "Tier").Column).Value = "Tier 1"
Case 2
ThisWorksheet.Cells(CurrentCell.Row, FindColumn(ThisWorksheet, "Tier").Column).Value = "Tier 2"
Case 3
ThisWorksheet.Cells(CurrentCell.Row, FindColumn(ThisWorksheet, "Tier").Column).Value = "Tier 3"
End Select
End If
So, if the value was 20x Attribute removal in D24, then in D25 I want it to Say