另一列中的日期的条件格式

Chasity
Chasity
编辑05/23/23 公式和函数

我需要使日期在一栏变成绿色或红色取决于他们是否完整。有一个卡片的到期日框,卡片完成日期需要变为绿色或红色,基于到达或错过到期日-或者如果盒子没有填写到期日的日期。请帮助。

标签:

答案

  • 吉纳维芙P。
    吉纳维芙P。 员工管理

    @Chasity

    我个人的做法是设置一个复选框列使用列式公式要检查想要显示为红色的行:

    =IF([截止日期]@row = "", 0, IF(或([牌组完成日期]@row >[截止日期]@row,[牌组完成日期]@row = ""), 1))

    截图2023-05-23 at 11.51.47.png

    然后你可以在这些复选框上设置条件格式:

    截图2023-05-23 (12.49.22.png)

    欢呼,

    吉纳维芙

  • 黛比·索亚历险记
    黛比·索亚历险记 ✭✭✭✭✭✭

    @Chasity

    在这里,我没有尝试用文字解释,而是创建了一个非常快速的示例表,告诉你如何获得正确的颜色。

    image.png

    使用IF语句设置一个辅助列,该语句将返回您想要的日期颜色,然后在条件格式框中使用该辅助列。我已经在一列中显示了我使用的公式,但我不得不用“”包围它,以使它显示(而不是执行!)您不需要在公式周围使用“”……

    我希望这对你有帮助

    亲切的问候

    黛比

帮助文章参考资料欧宝体育app官方888

想要直接在智能表中练习使用公式吗?

请查看公式手册模板!
It would look something like this:<\/p>

=COUNTIFS({状態 Status}, OR(@cell = \"未着手 Not Started\", @cell = \"進行中 In Progress\", @cell = \"現場確認 Field Review\", @cell = \"保留中(予算)On Hold (Funding)\", @cell = \"保留中 On Hold\"), {エリア Area}, @cell = \"Example1\")<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[{"tagID":254,"urlcode":"Formulas","name":"Formulas"}]},{"discussionID":105974,"type":"question","name":"Help creating a formula that generates the current fiscal year","excerpt":"The following formula is #UNPARSEABLE. I'm not sure why. Please help. =IF(MONTH(TODAY())>=7, YEAR(TODAY())&\"-\"&(YEAR(TODAY())+1), (YEAR(TODAY())-1)&\"-\"&YEAR(TODAY()))","categoryID":322,"dateInserted":"2023-06-02T19:06:56+00:00","dateUpdated":null,"dateLastComment":"2023-06-02T19:46:15+00:00","insertUserID":161705,"insertUser":{"userID":161705,"name":"Christina S.","url":"https:\/\/community.smartsheet.com\/profile\/Christina%20S.","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-02T19:44:40+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":null,"lastUserID":161705,"lastUser":{"userID":161705,"name":"Christina S.","url":"https:\/\/community.smartsheet.com\/profile\/Christina%20S.","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-02T19:44:40+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":2,"countViews":29,"score":null,"hot":3371469191,"url":"https:\/\/community.smartsheet.com\/discussion\/105974\/help-creating-a-formula-that-generates-the-current-fiscal-year","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/105974\/help-creating-a-formula-that-generates-the-current-fiscal-year","format":"Rich","tagIDs":[254],"lastPost":{"discussionID":105974,"commentID":378672,"name":"Re: Help creating a formula that generates the current fiscal year","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/378672#Comment_378672","dateInserted":"2023-06-02T19:46:15+00:00","insertUserID":161705,"insertUser":{"userID":161705,"name":"Christina S.","url":"https:\/\/community.smartsheet.com\/profile\/Christina%20S.","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-02T19:44:40+00:00","banned":0,"punished":0,"private":false,"label":"✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-06-02T19:45:43+00:00","dateAnswered":"2023-06-02T19:21:45+00:00","acceptedAnswers":[{"commentID":378667,"body":"

The concatenate operator in Smartsheet is + instead of &.<\/p>


<\/p>

=IF(MONTH(TODAY())>=7, YEAR(TODAY())+\"-\"+(YEAR(TODAY())+1), (YEAR(TODAY())-1)+\"-\"+YEAR(TODAY()))<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[{"tagID":254,"urlcode":"Formulas","name":"Formulas"}]},{"discussionID":105970,"type":"question","name":"Trying to evaluate multiple columns with an IF statement","excerpt":"I keep getting a syntax error for some reason but can't figure out why. I am basically trying to set a status icon of 'Sunny\" if the status of the risk is \"closed\" and if not closed, i am using the other icons based on the level of the risk. here is the formula: =IF([Status]@row = “Closed”, “sunny”, IF([Risk Score]@row <=…","categoryID":322,"dateInserted":"2023-06-02T17:58:00+00:00","dateUpdated":null,"dateLastComment":"2023-06-02T19:19:11+00:00","insertUserID":162035,"insertUser":{"userID":162035,"name":"Drew N.","title":"Program Manager","url":"https:\/\/community.smartsheet.com\/profile\/Drew%20N.","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-02T19:20:11+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":null,"lastUserID":45516,"lastUser":{"userID":45516,"name":"Paul Newcome","title":"","url":"https:\/\/community.smartsheet.com\/profile\/Paul%20Newcome","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/userpics\/082\/nQPUTVFKKWDJ2.jpg","dateLastActive":"2023-06-02T20:54:24+00:00","banned":0,"punished":0,"private":false,"label":"✭✭✭✭✭✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":3,"countViews":27,"score":null,"hot":3371464031,"url":"https:\/\/community.smartsheet.com\/discussion\/105970\/trying-to-evaluate-multiple-columns-with-an-if-statement","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/105970\/trying-to-evaluate-multiple-columns-with-an-if-statement","format":"Rich","tagIDs":[254],"lastPost":{"discussionID":105970,"commentID":378663,"name":"Re: Trying to evaluate multiple columns with an IF statement","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/378663#Comment_378663","dateInserted":"2023-06-02T19:19:11+00:00","insertUserID":45516,"insertUser":{"userID":45516,"name":"Paul Newcome","title":"","url":"https:\/\/community.smartsheet.com\/profile\/Paul%20Newcome","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/userpics\/082\/nQPUTVFKKWDJ2.jpg","dateLastActive":"2023-06-02T20:54:24+00:00","banned":0,"punished":0,"private":false,"label":"✭✭✭✭✭✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-06-02T18:44:44+00:00","dateAnswered":"2023-06-02T18:24:38+00:00","acceptedAnswers":[{"commentID":378641,"body":"

I think you are overcomplicating it. Try this instead:<\/p>

=IF([Status]@row = \"Closed\", \"sunny\", IF([Risk Score]@row <= 25, \"partly sunny\", IF([Risk Score]@row <= 50, \"cloudy\", IF([Risk Score]@row <= 90, \"rainy\", \"stormy\"))))<\/p>


<\/p>

It also looks like some of your quotes are slanted and others are straight up and down. The slanted ones are called \"Smart Quotes\" which (ironically enough) are not recognized as valid characters in Smartsheet formulas. You will need to either retype them here in the Community (which I did above already), directly in Smartsheet, or in a text editor such as Notepad (not Word).<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[{"tagID":254,"urlcode":"Formulas","name":"Formulas"}]}],"title":"Trending in Formulas and Functions ","subtitle":null,"description":null,"noCheckboxes":true,"containerOptions":[],"discussionOptions":[]}">

公式和函数趋势