IF Statement to return a Date value
I'd like to create an nested If Statement to return a date based on meeting a specific condition. I'd like to be able to "hardcode" the date in the IF statement. Here is a quick example =IF([Value]1 = "Option2", 4/23/2019, IF([Value]1 = "Option2", 4/24/2019, 4/25/2019)) . If the date is quote wrapped ed "4/24/2019" then it doesn't return a date but instead returns a text value. If the date is not quote wrapped then the date gets updated in the formula to ex: 4 / 23 / 2019 and it returns a #DATE EXPECTED error message.
Tags:
Comments
-
You'll need to use the Date function...
=IF(Value@row="Option 1", Date(2019, 04, 23), IF(Value@row="Option 2", Date(2019, 04, 24), Date(2019, 04, 25))
Would work.
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.8K Get Help
- 437 Global Discussions
- 138 Industry Talk
- 470 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 65 Community Job Board
- 486 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Want to practice working with formulas directly in Smartsheet?
Check out the Formula Handbook template!
Check out the Formula Handbook template!