I'm writing an Excel formula for work. I wanted to make it a little better. The Excel is filled with a bunch of info related to work.
I have it searching through column D looking for text (that corresponds to piece of hardware) then it matches that text with the same on sheet 2 and pastes in Column P whether that text (hardware) is active or inactive.
I was wanting to place some code in Column Q thats reads column P if it says inactive or active.
If it says inactive it then Searches Column A for what P# that text is connect to.
If you look at the picture you can see column A has test that read P-1, P-3. I want to essitenaly print that in Column Q next to the inatives so I can quickly see what P# that inactive is on.
I think the drawing kinda shows what I plan to do.
If it's easier it's ok if the code just goes over to column A and searches upward till it finds a value and just prints it.
It's ok if active and inactive have the P#s next it but I just need the inactive too have it. In image 2 is an example the finale product.
As shown in blue is the preferred solution where its only next to inactive ones.
Mostly bc the active ones do not need it for the process but if it's easier it totally fine if like red it just says it on every one.