function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
TinaBTinaB 

Calculating Case Age by Days

Trying to use the sample formula of
 
IF( {!IsClosed} , ROUND({!ClosedDate} - {!CreatedDate}, 0) ,
ROUND((NOW() - {!CreatedDate}),0))

IF( {!IsClosed} , ROUND({!ClosedDate} - {!CreatedDate}, 0) ,
ROUND((NOW() - {!CreatedDate}),0))

 
But it doesn't seem to like andy of the field names.  I have not changed the name of any of these fields can someone help?
Harry JamesHarry James
Try removing the exclamation points preceding the field names.  They are not necessary any longer.
TinaBTinaB
Yeah, I had tried that already.  Didn't make a difference.  But thanks anyway.
wgrwgr
This formula works for Case Age:

IF( IsClosed , ROUND(ClosedDate - CreatedDate, 0) ,
ROUND((NOW() - CreatedDate),0))

Cheers

Werner

Message Edited by wgr on 06-07-2007 11:33 PM

TinaBTinaB
Nope that one doesn't work.
 
IF( IsClosed , ROUND(ClosedDate - CreatedDate, 0) , ROUND((NOW() - CreatedDate),0))
Error: Field ClosedDate does not exist. Check spelling.
wgrwgr
Assuming now you are using the formula in Opportunities - this would be the formula for Opportunity Age:

IF( IsClosed , ROUND(CloseDate - TODAY() + NOW () - CreatedDate, 0) , ROUND((NOW() - CreatedDate),0))

Cheers,

Werner

TinaBTinaB
It's still not working.  Very wierd.  We have no custom code nor have we changed the name of any fields.  Pretty much just SF out of the box.
wgrwgr
I attached screenshots for the Opportunity Age Formula and the Case Age Formula.

Do you see any difference? Formula Return Type? This has to be "Number" with Decimal Places "0".

Does it help?

Cheers,

Werner

Message Edited by wgr on 06-08-2007 08:47 AM

Message Edited by wgr on 06-08-2007 08:53 AM

TinaBTinaB
Got it now!  Thanks for your help.