The dreaded #invalid data type
Hi guys,
I'm progressing with my basic formula however what do i need to add into the below formula as an example so i don't get the unsightly #invalid data type in a cell just because the start date is blank?
=IF(MONTH([Start Date]@row) = 1, "January", IF(MONTH([Start Date]@row) = 2, "February", IF(MONTH([Start Date]@row) = 3, "March", IF(MONTH([Start Date]@row) = 4, "April", IF(MONTH([Start Date]@row) = 5, "May", IF(MONTH([Start Date]@row) = 6, "June", IF(MONTH([Start Date]@row) = 7, "July", IF(MONTH([Start Date]@row) = 8, "August", IF(MONTH([Start Date]@row) = 9, "September", IF(MONTH([Start Date]@row) = 10, "October", IF(MONTH([Start Date]@row) = 11, "November", IF(MONTH([Start Date]@row) = 12, "December"))))))))))))
Answers
-
IFERROR. Toss that in the front and the value you want if an error occurs at the end. I just put 0. You could put "" to leave it blank
=IFERROR(IF(MONTH([start date]@row) = 1, "January", IF(MONTH([start date]@row) = 2, "February", IF(MONTH([start date]@row) = 3, "March", IF(MONTH([start date]@row) = 4, "April", IF(MONTH([start date]@row) = 5, "May", IF(MONTH([start date]@row) = 6, "June", IF(MONTH([start date]@row) = 7, "July", IF(MONTH([start date]@row) = 8, "August", IF(MONTH([start date]@row) = 9, "September", IF(MONTH([start date]@row) = 10, "October", IF(MONTH([start date]@row) = 11, "November", IF(MONTH([start date]@row) = 12, "December")))))))))))), 0)
-
Thanks Dan,
I understand now appreciate your help.
I tweaked the formula to the below so it just leaves it blank.
=IFERROR(IF(MONTH([start date]@row) = 1, "January", IF(MONTH([start date]@row) = 2, "February", IF(MONTH([start date]@row) = 3, "March", IF(MONTH([start date]@row) = 4, "April", IF(MONTH([start date]@row) = 5, "May", IF(MONTH([start date]@row) = 6, "June", IF(MONTH([start date]@row) = 7, "July", IF(MONTH([start date]@row) = 8, "August", IF(MONTH([start date]@row) = 9, "September", IF(MONTH([start date]@row) = 10, "October", IF(MONTH([start date]@row) = 11, "November", IF(MONTH([start date]@row) = 12, "December")))))))))))), "")
-
Cool deal happy to help!
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 64K Get Help
- 412 Global Discussions
- 220 Industry Talk
- 459 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 140 Just for fun
- 57 Community Job Board
- 461 Show & Tell
- 31 Member Spotlight
- 1 SmartStories
- 299 Events
- 38 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!