Ramballah
Active Member
- Joined
- Sep 25, 2018
- Messages
- 334
- Office Version
- 365
- Platform
- Windows
Hi,
I am looking for a formula that can find the first certain value if its there that also has certain conditions met.
First let me show you a simpler version of my spreadsheet:
So what I need is to find the very first "4" in the row that does not have one next to it, and the last "4" that does not have one next to it. I just need this per row, so not for all 4 rows in 1 formula, just 1 formula for 1 row.
But the issue comes as follows:
1. As you can see, the first 4 starts on column B which is the first of the month, However this can change dynamically from any column: A,B,C,D,E,F and G. Since not every month starts on the monday
2. As you can see, the last 4 is on column AF which is the last date of the month, However this can change dynamically from any column: AE,AF,AG,AH,AI,AJ and AK. Since not every month ends on a wednesday.
3. I only need to find this 4 if its on the 1st of the month or on the last day (28, 29, 30 or 31) of the month
4. The "4"'s need to be a single 4, and not paired up like B3:C3 or AE4:AF4
5. It can also happen that there is not a single 4 on the first or last day but just empty. That's fine I don't need those and I don't need the pairs.
6. If it's any important, there are other values used in the cells aswell, so isblank is not gonna be helpful.
So for row 3 there is one "4", row 4 has one "4", row 5 has one "4" and row 6 has none.
If it gives a clarification for someone: 4's are always paired, and the month ends for example on the 31st, then in the next month the other 4 will be on the 1st making it a pair. So I just need to find those 4's that are at the end/beginning of the months.
I hope someone can finally help me with this!
Thanks in advance,
Ramballah
I am looking for a formula that can find the first certain value if its there that also has certain conditions met.
First let me show you a simpler version of my spreadsheet:
So what I need is to find the very first "4" in the row that does not have one next to it, and the last "4" that does not have one next to it. I just need this per row, so not for all 4 rows in 1 formula, just 1 formula for 1 row.
But the issue comes as follows:
1. As you can see, the first 4 starts on column B which is the first of the month, However this can change dynamically from any column: A,B,C,D,E,F and G. Since not every month starts on the monday
2. As you can see, the last 4 is on column AF which is the last date of the month, However this can change dynamically from any column: AE,AF,AG,AH,AI,AJ and AK. Since not every month ends on a wednesday.
3. I only need to find this 4 if its on the 1st of the month or on the last day (28, 29, 30 or 31) of the month
4. The "4"'s need to be a single 4, and not paired up like B3:C3 or AE4:AF4
5. It can also happen that there is not a single 4 on the first or last day but just empty. That's fine I don't need those and I don't need the pairs.
6. If it's any important, there are other values used in the cells aswell, so isblank is not gonna be helpful.
So for row 3 there is one "4", row 4 has one "4", row 5 has one "4" and row 6 has none.
If it gives a clarification for someone: 4's are always paired, and the month ends for example on the 31st, then in the next month the other 4 will be on the 1st making it a pair. So I just need to find those 4's that are at the end/beginning of the months.
I hope someone can finally help me with this!
Thanks in advance,
Ramballah