I am looking at having a VBA run with 2 conditions to autofill or pull data from another worksheet in the excel file. I have not finished adding all the locations, but i have added 2 different ones to test out on.
Currently on my Shift Notes Tab, I have a formula in the cell ranges of C9:F12 for a specific site (B7), however I would love it if I can create a system where it would pull the data from a set range instead that way if I select a different site (B7) then it would auto-fill the cell with the cell either a code or from a cell range in a different tab (Break Times).
For example, where currently it shows ABQ1 in Range B7 and Night 10 Hour in Range B8, then Range C9 would equal Worksheet Break Time Range E3.
This is my current VBA Module ( I would extend this to all my sites once I can confirm it works, I'd have at least 20 different sites):
Sub If_And()
Worksheets("Shift Notes").Select
If Range("B7") = "ABQ1" And Range("B8") = "Night 10 Hour" Then
Range("C9") = Worksheets("Break Times")("E3")
End Sub
Currently on my Shift Notes Tab, I have a formula in the cell ranges of C9:F12 for a specific site (B7), however I would love it if I can create a system where it would pull the data from a set range instead that way if I select a different site (B7) then it would auto-fill the cell with the cell either a code or from a cell range in a different tab (Break Times).
For example, where currently it shows ABQ1 in Range B7 and Night 10 Hour in Range B8, then Range C9 would equal Worksheet Break Time Range E3.
This is my current VBA Module ( I would extend this to all my sites once I can confirm it works, I'd have at least 20 different sites):
Sub If_And()
Worksheets("Shift Notes").Select
If Range("B7") = "ABQ1" And Range("B8") = "Night 10 Hour" Then
Range("C9") = Worksheets("Break Times")("E3")
End Sub