Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

RB11 vs RB10

edited January 2010 in General
Hi,

One report I set an autosearch value in code as

ppReport.AutoSeachFields[x].SearchExpression := DateTimeToStr(ADateTime);

In RB10.06 this works ok. In RB11.06 this results in following exception.
RB11.07 doesn't generate the exception but the result is incorrect. I think
it's because the time part is not parsed well and only the hours and minutes
are parsed.
If needed I can look into this more.

Using RB11.07, D2007, IBX

Kind regards,
Jeroen R?ttink

============================================================================
==
= 12-1-2010 9:41:12
=
============================================================================
==
Invalid floating point operation.

Exception class: EInvalidOp
Exception message: Invalid floating point operation.
Exception address: 0040F414
----------------------------------------------------------------------------
--
Stack list, generated 12-1-2010 9:41:12
[0040F414] SysUtils.DateTimeToTimeStamp
[00431747] Classes.TComponent.SetReference
[0040F759] SysUtils.DecodeDateFully
[0040DC7F] SysUtils.FormatBuf
[0040F89B] SysUtils.DecodeDate
[0040FBDE] SysUtils.GetDate
[0041014A] SysUtils.AppendFormat
[0041069E] SysUtils.DateTimeToString
[00410337] SysUtils.AppendFormat
[0041063E] SysUtils.AppendFormat
[0040FC1D] SysUtils.GetTime
[00410568] SysUtils.AppendFormat
[0041063E] SysUtils.AppendFormat
[0040630F] System.@LStrDelete
[0040ECB5] SysUtils.FloatToDecimal
[0040EC53] SysUtils.FloatToDecimal
[004106C0] SysUtils.DateTimeToString
[00403214] System.@GetMem
[00405E58] System.@NewAnsiString
[00427D61] Classes.TStringList.Get
[0040EEE1] SysUtils.TextToFloat
[00861D29] ppASField.TppSearchValueList.GetDateTimeFormat
[00861D6E] ppASField.TppSearchValueList.GetDateTimeFormat
[00410722] SysUtils.FormatDateTime
[00861F60] ppASField.TppSearchValueList.GetSearchExpressionForDateTime
[00861E13] ppASField.TppSearchValueList.GetSearchExpression
[00861084] ppASField.TppAutoSearchField.GetSearchExpression
[009EC6D1] daQueryDataView.TdaQueryDataView.AutoSearchFieldChangeEvent
[00860AFD] ppASField.TppAutoSearchField.DoOnChange
[00860BFA] ppASField.TppAutoSearchField.SetSearchExpression
[00B27D94] uPrinten.TDlgPrinten.ppReportGetAutoSearchValues (Line 279,
"uPrinten.pas" + 12)
[00868235] ppReport.TppReport.DoOnGetAutoSearchValues
[008680CD] ppReport.TppReport.ShowAutoSearchDialogBeforePrinting
[00867FC3] ppReport.TppReport.Print
[00B285BF] uPrinten.TDlgPrinten.PrintReport (Line 511, "uPrinten.pas" + 65)
[00B29A6E] uIPrintProvider.TPrintProvider.PrintReport (Line 204,
"uIPrintProvider.pas" + 6)
[00BFE09F] uWzdBestelling.TWzdBestelling.PrintReport (Line 1017,
"uWzdBestelling.pas" + 7)
[00BFE708] uWzdBestelling.TWzdBestelling.GenerateLockerAssignments (Line
1159, "uWzdBestelling.pas" + 52)
[00BFE263] uWzdBestelling.TWzdBestelling.ProcessOrders (Line 1053,
"uWzdBestelling.pas" + 2)

Comments

  • edited January 2010
    Hi Jeroen,

    If possible, please send a simple example demonstrating the issue in RB
    11.07 to support@digital-metaphors.com. In my current testing (using the
    Dutch regional setting on my machine) I was unable to recreate the issue
    using the DBDEMOS database, orders table. Below was the code I tried that
    functioned correctly...

    var
    lDateTime: TDateTime;
    begin

    lDateTime := StrToDateTime('12-04-1988 12:00:00 A.M.');

    ppReport1.AutoSearchFields[0].SearchExpression :=
    DateTimeToStr(lDateTime);

    ppReport1.Print;

    end;

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.