morbenforsen
New Member
- Joined
- Jul 4, 2015
- Messages
- 20
Hello, I'm trying to use VBA to replace numerous formulas. I am hoping someone might be able to help me with a quick and clean way to do the following based on my example:
I want to;
-search current worksheet in range (column c starting at c3:c13)
-if 'NO' found then mark 'NO' in cell on same row in column D and continue searching down the range in col C.
-if 'YES' found, then search ('some_other_column' in 'a_different_worksheet) for value found in column b (on this worksheet) on the same row. (in example below $37.50)
-if this value ($37.50 or whatever) is found in the different worksheet, then mark 'YES' in cell on same row in column D of THIS worksheet.
-if this value is NOT found in the other worksheet, then mark 'NO' in cell on same row in column D of THIS worksheet.
I hope I am explaining this clearly. Please go easy because while i have a small amount of experience with VBA it has been several years since I have visited this. Any help is most graciously appreciated
<tbody>
</tbody>
I want to;
-search current worksheet in range (column c starting at c3:c13)
-if 'NO' found then mark 'NO' in cell on same row in column D and continue searching down the range in col C.
-if 'YES' found, then search ('some_other_column' in 'a_different_worksheet) for value found in column b (on this worksheet) on the same row. (in example below $37.50)
-if this value ($37.50 or whatever) is found in the different worksheet, then mark 'YES' in cell on same row in column D of THIS worksheet.
-if this value is NOT found in the other worksheet, then mark 'NO' in cell on same row in column D of THIS worksheet.
I hope I am explaining this clearly. Please go easy because while i have a small amount of experience with VBA it has been several years since I have visited this. Any help is most graciously appreciated
1 | a | b | c | d |
2 | Entity | cost | Paid | Cleared |
3 | bucket 1 | $269.00 | No | No |
4 | bucket 2 | $37.50 | Yes | Yes |
5 | bucket 3 | $100.06 | Yes | No |
6 | bucket 4 | $51.71 | Yes | |
7 | bucket 5 | $167.19 | Yes | |
8 | bucket 6 | $180.00 | Yes | |
9 | bucket 7 | $53.75 | Yes | |
10 | bucket 8 | $266.00 | Yes | |
11 | bucket 9 | $106.00 | Yes | |
12 | bucket 10 | $212.34 | Yes | |
13 | bucket 11 | $19.95 | Yes |
<tbody>
</tbody>