Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

if(iserror()) Question

Status
Not open for further replies.

Cordury2

Technical User
Jan 22, 2005
55
US
I have dates in column J, in Column K I just want to return the month. However, I do not have dates is every row. So I attempted to use a is-iserror.... Simple enough or so I thought. Below is my formula.

=IF(ISERROR(MONTH(J19)),"",(MONTH(J19)))

It seems to work fine, except it is placing the number "1" where all dates (column J) are blank. I am assuming since there is not a # reference in these blank cells, if(iserror is not the way to go. I guess I could use just an if Statement.


Sorry, I answered my own question.

However, I do have a little "matrix" at the bottom of the sheet that I use to return expenses by quater using the SUMPRODUCT function. Is there anyway I could use this Matrix to look at the date in column J and return the fiscal quarter without having a sheet that contains every single date in one column and the respective quarter in the next and then do a vlookup?
 
How about using something like

[COLOR=blue white]=if(month(a1)<3,1,if(month(a1)<6,2,if(month(a1)<9,3,4)))[/color]

to figure the quarter?

[tt]-John[/tt]
________________________
To get the best answers fast, please read faq181-2886
 
That is a good idea, I will have to adjust it though because, out fiscal year begins in February (month 2) and ends in January (month 1).
 
GOT it. I used your idea of the embedded if statement but referenced my fiscal quaterly matrix.

p1012:n1014 equals my dates and fiscal quaters.

Column O = The Start Date
Column P = The End Date
Column N = the Quater!



=IF(K9="","",IF(J9<$P$1012,$N$1012,IF(J9<$P$1013,$N$1013,IF(J9<$P$1014,$N$1014,"Q4"))))
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top