Formulas Work Only One Line and Not Any Copied Down Below

brenda1996

New Member
Joined
Aug 30, 2018
Messages
29
Hi again,

Looking for some help as to why two formulas I have in my spreadsheet work perfect as intended but anything below that one line I copied down to will not.

IF(AND(C3=365,OR(D3="MON",D3="YR",D3="D")),"SHOULD BE DAY","") and IF(AND(C3<>365,OR(D3="DAY",D3="D")),"SHOULD BE MON or YR","") are in separate columns.

When I play with the data in columns C and D I get the expected results for only that one line. Formulas are the same copied down with the exception of line number.

The only way I can get formulas to work was to copy first line entirely twice below it.

In the snippet the first 3 rows are expected results, everything below is not and each cell was copied down from the first row. :(

The last four rows Columns E and F should both be blank and in first row. The fourth row should be the same as the second row.

Any help is sincerely appreciated as I have run into a dead end and about fixing to start pulling my hair out!

Brenda
 

Attachments

  • Capture.JPG
    Capture.JPG
    50.1 KB · Views: 12

Excel Facts

How can you turn a range sideways?
Copy the range. Select a blank cell. Right-click, Paste Special, then choose Transpose.
If be checking your cells where your result is not as expected. Are there trailing spaces etc after "DAY"?
 
Upvote 0
Ok split it out. Test these:

=C3=365
=OR(D3="MON",D3="YR",D3="D")

To give you a clue about where the problem lies. The formulas themselves dont look to be the problem. Looks a problem with the data in C or D
 
Upvote 0
Ok split it out. Test these:

=C3=365
=OR(D3="MON",D3="YR",D3="D")

To give you a clue about where the problem lies. The formulas themselves dont look to be the problem. Looks a problem with the data in C or D
I just tried the CLEAN function on the data and that usually takes care of issues but had no effect this time, same result. trying to figure out how I should test with your direction.
 
Upvote 0
In any spare cell. Looks like G3 & H3 would be good candidates. Then drag down. If you think your data could be 'dirty' then also try =LEN(C3) and =LEN(D3). Do they give expected numbers? That is does 365 produce 3 for example.
 
Upvote 0
In any spare cell. Looks like G3 & H3 would be good candidates. Then drag down. If you think your data could be 'dirty' then also try =LEN(C3) and =LEN(D3). Do they give expected numbers? That is does 365 produce 3 for example.
I get a True and a False when using those formulas in G and H. :(
 
Upvote 0
So is that unexpected? I cant see your sheet dont forget. You should be getting lots of TRUE and FALSE if you are testing the sample you gave. What you are looking for is where you see an unexpected result. Then test that cell with the LEN formula.
 
Upvote 0

Forum statistics

Threads
1,214,983
Messages
6,122,583
Members
449,089
Latest member
Motoracer88

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top