C1FlexReport .708: "DateDiff" fails for hour difference

Posted by: wknauf on 26 May 2025, 10:08 am EST

  • Posted 26 May 2025, 10:08 am EST - Updated 26 May 2025, 10:16 am EST

    See attached sample: it renders a report by loading a xml data source.

    FlexReportError_2025-05-26.zip

    We handle the event “C1FlexReport.Report_ReportError”, and this is raised with .708. with this error:

    System.ArgumentException: Evaluate expression '': Value does not fall within the expected range.
     ---> System.ArgumentException: Value does not fall within the expected range.
       at bu.h(c a, DateTime b, DateTime c, CultureInfo d, b e, a f)
       at bu.i(String a, Object b, Object c, CultureInfo d, b e, a f)
       at C1.Report.ScriptEngine.ParmExpression.Evaluate()
       at C1.Win.FlexReport.ScriptEngine.ParmExpression.Evaluate()
       at bn.Evaluate()
       at C1.Report.ScriptEngine.ParmExpression.Parm(Int32 i)
       at C1.Report.ScriptEngine.ParmExpression.ParmInt(Int32 i)
       at C1.Report.ScriptEngine.ParmExpression.Evaluate()
       at C1.Win.FlexReport.ScriptEngine.ParmExpression.Evaluate()
       at C1.Report.ScriptEngine.ParmExpression.Parm(Int32 i)
       at C1.Report.ScriptEngine.ParmExpression.Evaluate()
       at C1.Win.FlexReport.ScriptEngine.ParmExpression.Evaluate()
       at C1.Report.ScriptEngine.ReportScriptContextBase.Evaluate(Expression expression, Object onError, Object& value)
       --- End of inner exception stack trace ---
    

    I think it is caused by this field which executes “DateDiff (“h”, date1, date2)” to calculate the hour difference:

    Seems you don’t support this hour mode any more? It also fails for “d” like “day difference”

    See https://www.w3schools.com/asp/func_datediff.asp

    It worked with .700.

    Best regards

    Wolfgang

  • Posted 27 May 2025, 8:21 am EST

    Hello Wolfgang,

    Thank you for sharing details. We were able to observe the behavior.

    We have escalated it to the development team for further insights. [Internal Tracking ID: C1WIN-34085]

    We’ll update you as soon as we have information.

    Regards,

    Uttkarsh.

  • Posted 11 June 2025, 12:32 am EST

    Hello Wolfgang,

    As per the team, the issue is a bug and the ETA for the fix is 2025 v1 hotfix 2.

    [Bug Tracking ID: C1WIN-34136]

    Regards,

    Uttkarsh.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels