Skip to main content
Solved

Leave Blank if #Error

  • August 23, 2023
  • 2 replies
  • 526 views

Kelly_Vorrasi1
Forum|alt.badge.img+9

I've tried this several times and nothing I do seems to work. I'm trying to wrap this formula in an IF(ISERROR( so that if there is an error it stays blank and I can't get it to work. I'm working with a formula field that sometimes displays text and sometimes a date. if it's a date, it should be used in the formula to give me the new date and if it's text, I just want the new field to remain blank. 

IF( AND( {PAY2 TV From}="PAY1", {PAY1 Formula/Manual} ), DATETIME_FORMAT(DATEADD({PAY1 Formula/Manual},{PAY2 TV Amount},{PAY2 TV Time Frame}),"LL"), IF( AND( {LTR}, {PAY2 TV From}="LTR" ), DATETIME_FORMAT(DATEADD({LTR},{PAY2 TV Amount},{PAY2 TV Time Frame}),"LL"), "" ) )

 

Best answer by Sho

Need to determine if the output of the "PAY1 Formula/Manual" field is a date or a string

 

IF( AND( {PAY2 TV From}="PAY1", NOT(ISERROR(DATESTR(({PAY1 Formula/Manual}))) ), DATETIME_FORMAT(DATEADD({PAY1 Formula/Manual},{PAY2 TV Amount},{PAY2 TV Time Frame}),"LL"), IF( AND( {LTR}, {PAY2 TV From}="LTR" ), DATETIME_FORMAT(DATEADD({LTR},{PAY2 TV Amount},{PAY2 TV Time Frame}),"LL"), "" ) )

 

2 replies

Forum|alt.badge.img+21
  • Inspiring
  • Answer
  • August 23, 2023

Need to determine if the output of the "PAY1 Formula/Manual" field is a date or a string

 

IF( AND( {PAY2 TV From}="PAY1", NOT(ISERROR(DATESTR(({PAY1 Formula/Manual}))) ), DATETIME_FORMAT(DATEADD({PAY1 Formula/Manual},{PAY2 TV Amount},{PAY2 TV Time Frame}),"LL"), IF( AND( {LTR}, {PAY2 TV From}="LTR" ), DATETIME_FORMAT(DATEADD({LTR},{PAY2 TV Amount},{PAY2 TV Time Frame}),"LL"), "" ) )

 


Kelly_Vorrasi1
Forum|alt.badge.img+9
  • Author
  • Known Participant
  • August 23, 2023

Amazing that worked beautifully!!