Joined: 22 May 2010
Online Status: Offline
Posts: 15
Topic: If Then Else DateDiff Forumla ? Posted: 07 Nov 2010 at 3:26am
OK I would think this would be straight forward but I am getting an error with this formula
IF IsNull ({_TELMASTE_.CLOSED ON}) Then "Open" Else DateDiff ("d",{_TELMASTE_.DATE OPEN} ,{_TELMASTE_.CLOSED ON})
The Datediff works by its self and so does the Isnull statement but when combined together with a If Then Else its says a string is required here then highlights the DateDiff line.
but you need to convert your 'else' statement as String.
because if your condition is 'true' it will print a text/string ("open"). so if the condition is 'false' then you need to print the result as text/string rather than 'date' format (convert your datediff as string).
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum