Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#1046 DateTime class in Citrix environment raises error condition

4.1.1
closed
Rick McGuire
none
5
2013-11-22
2012-02-15
Danny De Wilde
No

We are moving over to a Citrix environement and I transfering my OORexx scripts to our Citrix servers. In the first script I am testing with using OODialogs (RC files) I got the following error messages:
Error 88 running C:\work.ooRexx\wc\main.4.1.0.beta\Win32Rel\CoreClasses.orx line 3286: Invalid argument
Error 88.903: Argument offset must be a whole number; found "59.999991666666667

I don't really know where to start looking. In the first instance I believe I had something to with pixels/dialog units. I did change a couple of things but it didn't really work.

All help would be more than welcome.

Discussion

1 2 > >> (Page 1 of 2)
  • Mark Miesfeld
    Mark Miesfeld
    2012-02-15

    First, these error messages

    Error 88 running C:\work.ooRexx\wc\main.4.1.0.beta\Win32Rel\CoreClasses.orx line 3286: Invalid argument
    Error 88.903: Argument offset must be a whole number; found "59.999991666666667

    should be preceded by an instruction trace. Please copy and paste into this bug report the entire message. It should most likely look more like this:

       *-* Compiled code
    23 *-* self~addButton(IDOK, 59.9999, 399, 50, 14, "Ok", "DEFAULT")
       *-* Compiled code
    13 *-* self~create(30, 30, 257, 423, "Simple Dialog", "CENTER")
       *-* Compiled code
       *-* Compiled code
     3 *-* dlg = .SimpleDialog~new( , "simple.h")
    

    Error 88 running C:\work.ooRexx\other\feature.requests\myUserDlg.rex line 3: Invalid argument
    Error 88.907: Argument 2 must be in the range -2147483648 to 2147483647; found "59.9999"

    Second, from the output, it looks like you are using a beta version of 4.1.0:

    C:\work.ooRexx\wc\main.4.1.0.beta\Win32Rel

    you need to upgrade to the release version of 4.1.0. Several bugs found during the beta phase were fixed in the release version.

    Third, the problem is that somewhere in your script a fractional number is being used as an argument where a whole number is requried. This could be in your code, or it could be a bug in ooDialog if you are using some of the common public routines or dialogs. Such as a MultiInputBox dialog. Or, if you are using certain methods of the UserDialog class such as the createOkCancelRightBottom() method.

    Since you mention pixels / dialog units, a pixel is a whole number, you can not have 59.99 pixels. You can only have 59 pixels or 60 pixels. A common mistake is to use a calculation that produces a fractional number in some circumstances. You can fix that by using trunc() on the calculated value.

    In any case, we can easily locate the problem if you provide the entire error message output including the instruction trace.

    If by some chance there is not an instruction trace printed out, then you will need to attach either your script, or some other working program that produces the error, for me to debug it.

    Thanks.

     
  • Danny De Wilde
    Danny De Wilde
    2012-02-17

    Hi Mark,

    I've have download the OOREXX source code and looked into coreclass.orx file. My script dumped when the ValidWhole method was executed. So I re-analysed my problem.

    In fact it has nothing to do with pixels/dialog units. It is, when running in the Citrix environement and a .datetime class is created it crashes.

    See trace output below;
    Microsoft Windows [Version 5.2.3790]
    (C) Copyright 1985-2003 Microsoft Corp.

    J:>cd oorexx

    J:\OORexx>cd src

    J:\OORexx\SRC>dir
    Volume in drive J is ME-RE01-WTS01
    Volume Serial Number is 5647-E0CB

    Directory of J:\OORexx\SRC

    07/11/2011 23:03 <DIR> .
    07/11/2011 23:03 <DIR> ..
    30/12/2011 12:00 <DIR> D
    16/01/2012 16:54 <DIR> P
    0 File(s) 0 bytes
    4 Dir(s) 36.745.736.192 bytes free

    J:\OORexx\SRC>cd p

    J:\OORexx\SRC\P>rexx finin01
    12 - Trace ON
    200 - Signal on USER DLGError NAME DLGException
    202 - forward class (super) continue
    203 - InitRet = Result
    206 - ResourceFile = 'RC\IMPORT.RC'
    207 - If \ self~Load(ResourceFile, ) = 0
    315 - If (self~DefineDialog:super) = 0
    317 - Then
    317 - self~SETUP_MENUBAR()
    387 - self~CreateMenu()
    391 - self~AddPopupMenu("Accounting")
    392 - self~AddMenuItem("Company codes tabel" , 101,,"CO_TABLE")
    393 - self~AddMenuItem("Trading partner tabel" , 102,,"TP_TABLE")
    395 - self~AddMenuSeparator
    396 - self~AddMenuItem("IRS Chart of account (MIRS)" , 111,,"MIRS")
    397 - self~AddMenuItem("IFRS Chart of account (MNIF)" , 112,,"MNIF")
    398 - self~AddMenuItem("MAR Chart of account (MMAR)" , 113,,"MMAR")
    400 - self~AddMenuSeparator
    401 - self~AddMenuItem("Ledger Z1" , 115,,"Z1_Ledger")
    402 - self~AddMenuItem("Ledger Z2" , 116,"DISABLED","Z2_
    Ledger")
    403 - self~AddMenuItem("Ledger Z3" , 117,,"Z3_Ledger")
    405 - self~AddMenuSeparator
    406 - self~AddMenuItem("Controlling (KSB1)" , 120,,"KSB1")
    408 - self~AddMenuSeparator
    409 - self~AddMenuItem("Cost Centers" , 130,,"CostCenters")

    411 - self~AddMenuSeparator
    412 - self~AddMenuItem("Account determination" , 140,,"ACC_DETAIL")
    413 - self~AddMenuItem("SAP Internal code dummies" , 141,,"SAP_DUMMY_IC"
    )
    416 - self~AddMenuSeparator
    417 - self~AddMenuItem("..." , 199, "GRAYED DISABL
    ED END")
    424 - self~AddPopupMenu("Credit Control")
    425 - self~AddMenuItem("IM10", 220,,"IM10")
    426 - self~AddMenuItem("IM10 deelbetalingen", 221,,"IM10_DEELBETALINGEN")
    427 - self~AddMenuSeparator
    428 - self~AddMenuItem("ECA - De Meuter (A1091)", 222,,"ECA_DETAILS_A1091")

    429 - self~AddMenuItem("ECA - IUSTUS (L4303)", 223,,"ECA_DETAILS_L4303")

    430 - self~AddMenuItem("ECA - Samenvoegen ECA details naar ECA)", 224, ," E
    CA_JOIN_MAIN")
    431 - self~AddMenuSeparator
    432 - self~AddMenuItem("Aanmaken 'BZ Klanten' tabel", 225,,"BZ_KLANTEN")
    433 - self~AddMenuItem("Aanmaken 'Dubieuze Klanten' tabel", 226,,"DUBIEUZE_
    KLANTEN")
    434 - self~AddMenuItem("Aanmaken 'Dubieuze Vorderingen' tabel", 227,,"DUBIE
    UZE_VORDERINGEN")
    435 - self~AddMenuItem("Aanmaken 'Overdues' tabel", 228,,"OVERDUES")
    436 - self~AddMenuSeparator
    437 - self~AddMenuItem("Aanmaken 'LAGENT (en LINTERN/LVERZ) tabel'", 229,,"
    CC_SALDI")
    438 - self~AddMenuSeparator
    439 - self~AddMenuItem("KW10", 230,,"KW10")
    440 - self~AddMenuSeparator
    441 - self~AddMenuItem("Aanmaken 'VMB-LIJST09' tabel " , 231,,"VMB_LIJST09"
    )
    442 - self~AddMenuItem("Aanmaken 'VMB_BZOPVOLG' tabel", 232,,"VMB_BZOPVOLG"
    )
    444 - self~AddMenuSeparator
    445 - self~AddMenuItem("...", 299, "GRAYED DISABLED END")
    448 - self~AddPopupMenu("Fiscaliteit")
    449 - self~AddMenuItem("Aanmaken 'fiscal ledger' tabel",300,"","FISCAL_LEDG
    ER")
    450 - self~AddMenuItem("Aanmaken Vennb. bestanden (Kluwer soft) ",301,"CHEC
    KED","KLUWER")
    451 - self~AddMenuSeparator
    452 - self~AddMenuItem("Schade data voor fiscale fiche 281.00",310,,"Fiche_
    281_00")
    453 - self~AddMenuSeparator
    454 - self~AddMenuItem("...", 399, "GRAYED DISABLED END")
    456 - self~AddPopupMenu("ex-Avero MIS/IAS")
    457 - self~AddMenuItem("Chart of accounts",400,"","COA_AVERO")
    458 - self~AddMenuItem("Saldibalansen",401,"","TRIAL_BALANCE_AVERO")
    459 - self~AddMenuSeparator
    460 - self~AddMenuItem("...", 499, "GRAYED DISABLED END")
    462 - self~AddPopupMenu("Risk")
    463 - self~AddMenuItem("SST Mapping tabel",500,"","SST_MAPPING")
    464 - self~AddMenuItem("Aanmaken 'SST Ledger' tabel ",501,"","SST_LEDGER")
    465 - self~AddMenuSeparator
    466 - self~AddMenuItem("Solvency II Groups",502,"","SOLVENCY2_GROUPS")
    467 - self~AddMenuItem("Solvency II Mapping table",503,"","SOLVENCY2_MAPPIN
    G")
    468 - self~AddMenuItem("Aanmaken 'Solvency II Ledger' tabel ",504,"","SOLVE
    NCY2_LEDGER")
    469 - self~AddMenuSeparator
    470 - self~AddMenuItem("...", 599, "GRAYED DISABLED END")
    472 - self~AddPopupMenu("Nateus")
    473 - self~AddMenuItem("Inlezen CoA",600,"","NATEUS_COA")
    474 - self~AddMenuItem("Inlezen mapping tabel",601,"","NATEUS_COA_MAPPING")

    475 - self~AddMenuItem("Inlezen saldibalansen",602,"","NATEUS_TRIAL_BALANCE
    _MAIN")
    476 - self~AddMenuSeparator
    477 - self~AddMenuItem("...", 699, "GRAYED DISABLED END")
    480 - self~AddPopupMenu("Help")
    481 - self~AddMenuItem("Help",800,"END","Help")
    482 - self~AddMenuSeparator
    485 - self~AddPopupMenu("Exit", "END")
    486 - self~AddMenuItem("Exit",900,"END","Cancel")
    487 - self~AddMenuSeparator
    490 - RETURN
    215 - self~ConnectButton(1,'OK')
    216 - self~ConnectButton(2,'Cancel')
    217 - self~ConnectButton(9,'Help')
    223 - self~IAM_FullFileName = .nil
    224 - self~IAM_FolderName = .nil
    225 - self~IAM_FileName = .nil
    226 - self~IAM_CleanUp_Counter = .nil
    228 - .local['FullFileName'] = .nil
    230 - .environment['VMB_BZOPVOLG.FULLFILENAME'] = .NIL -- validation
    !!!!!
    231 - .environment['LAST_ERROR_MESSAGE'] = .NIL -- validation
    !!!!!
    234 - Return InitRet
    244 - Expose curPB, wLB, SDateTime, wErrorEntry
    250 - Signal on USER DLGError NAME DLGException
    252 - InitDlgRet = self~InitDialog:super
    254 - self~ListDrop(30)
    256 - self~SetListWidth(30,10000)
    258 - wLB = self~GetListBox(30)
    263 - self~SetListTabulators(30, 10, 100)
    265 - wErrorEntry = self~GetEditControl(99)
    268 - wErrorEntry~SetColor(7,13 )
    270 - wErrorEntry~SetText(.ERRORLIST['I000'])
    272 - self~SetMenu
    274 - self~SetListBox_Init_Values()
    3244 - TRACE ?r
    +++ "WindowsNT METHOD J:\OORexx\SRC\P\FININ01.REX"
    3245 - Signal on USER DLGError NAME DLGException
    +++ Interactive trace. "Trace Off" to end debug, ENTER to Continue. +++

    3251 - self~AddListEntry(30, .DateTime~new()||'9'x||'Programma 'self~IAM_Scr
    iptName' gestart...')
    3251 - self~AddListEntry(30, .DateTime~new()||'9'x||'Programma 'self~IAM_Scr
    iptName' gestart...')
    274 - self~SetListBox_Init_Values()
    2733 - self~InitDialog
    702 - if self~startit(icon, nomodal) \= 0
    76 - ret = .local['MyDialog']~Execute('SHOWTOP')
    Error 88 running C:\work.ooRexx\wc\main.4.1.0.beta\Win32Rel\CoreClasses.orx line
    3286: Invalid argument
    Error 88.903: Argument offset must be a whole number; found "59.999983766666666
    7"

    I have then tried using REXXTRY to test one and other and these are the results;
    J:\OORexx\SRC\P>rexxtry
    REXX-ooRexx_4.1.0(MT) 6.03 5 Dec 2010
    rexxtry.rex lets you interactively try REXX statements.
    Each string is executed when you hit Enter.
    Enter 'call tell' for a description of the features.
    Go on - try a few... Enter 'exit' to end.
    test = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999961833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    say date()
    17 Feb 2012
    ........................................... rexxtry.rex on WindowsNT
    say date(s)
    20120217
    ........................................... rexxtry.rex on WindowsNT
    test = .datetime~new(DATE(S)
    Oooops ! ... try again. Unmatched "(" or "[" in expression
    Left parenthesis "(" in position 20 on line 161 re
    quires a corresponding right parenthesis ")"
    rc = 36.901 ............................... rexxtry.rex on WindowsNT
    test = .datetime~new(DATE(S))
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999838166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    test = .datetime~new(,0)
    Oooops ! ... try again. Incorrect call to method
    Missing argument in method; argument 1 is required

    rc = 93.903 ............................... rexxtry.rex on WindowsNT
    test = .datetime~new(2012,02,17,0)
    ........................................... rexxtry.rex on WindowsNT
    say test
    2012-02-17T00:00:00.000000
    ........................................... rexxtry.rex on WindowsNT

    Some other tests;
    J:\OORexx\SRC\P>rexxtry
    REXX-ooRexx_4.1.0(MT) 6.03 5 Dec 2010
    rexxtry.rex lets you interactively try REXX statements.
    Each string is executed when you hit Enter.
    Enter 'call tell' for a description of the features.
    Go on - try a few... Enter 'exit' to end.
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999892833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new(2012,02,17)
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999849833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new(2012,02,17,12,10)
    Oooops ! ... try again. Incorrect call to method
    Not enough arguments in method; 6 expected
    rc = 93.901 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new(2012,02,17,12,10,10)
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999927833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new(2012,02,17,12,10,10,0)
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999988333333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new(2012,02,17,12,10,10,0)
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999942166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new(date(S))
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999994166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new(date(e))
    Oooops ! ... try again. Incorrect call to routine
    DATE argument 2, "17/02/12", is not in the format
    described by argument 3, "F"
    rc = 40.19 ................................ rexxtry.rex on WindowsNT
    t = .datetime~new(date())
    Oooops ! ... try again. Incorrect call to routine
    DATE argument 2, "17 Feb 2012", is not in the form
    at described by argument 3, "F"
    rc = 40.19 ................................ rexxtry.rex on WindowsNT
    t = .datetime~new(date(e))
    Oooops ! ... try again. Incorrect call to routine
    DATE argument 2, "17/02/12", is not in the format
    described by argument 3, "F"
    rc = 40.19 ................................ rexxtry.rex on WindowsNT
    t = .datetime~fromEuropeanDate(date(e))
    Oooops ! ... try again. Invalid argument
    Argument date is not in a valid format; found "17/
    02/12"
    rc = 88.918 ............................... rexxtry.rex on WindowsNT
    t = .datetime~fromEuropeanDate
    Oooops ! ... try again. Incorrect call to method
    Not enough arguments in method; 1 expected
    rc = 93.901 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999998666666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999991"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999923666666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999961"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999873166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999953"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999876666666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999956666666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999850833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999932166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999993"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999885833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999986833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.

    rexxtry.rex: Enter 'exit' to end. Or '?' for online REXX help.
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999915166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    99999545"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999911"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999847166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999866833333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999949"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999925333333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999964333333333"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT
    t = .datetime~new
    Oooops ! ... try again. Invalid argument
    Argument offset must be a whole number; found "59.
    9999878166666667"
    rc = 88.903 ............................... rexxtry.rex on WindowsNT

    Concerning the version;
    I downloaded and installed the latest 4.1 verson (REXX.EXE version 4.1.0.6441 REXX.EXE) and it did reproduced message "Error 88 running C:\work.ooRexx\wc\main.4.1.0.beta\Win32Rel\CoreClasses.orx line 3286: Invalid argument" as if it is a beta version.

    Thanks in advance for any help.

    Danny De Wilde

     
  • Mark Miesfeld
    Mark Miesfeld
    2012-02-18

    Hi Danny,

    If I use RexxTry, I don' see what you do:

    C:\work.ooRexx\bug.work\dateTime>rexxtry
    REXX-ooRexx_4.1.0(MT) 6.03 5 Dec 2010
    rexxtry.rex lets you interactively try REXX statements.
    Each string is executed when you hit Enter.
    Enter 'call tell' for a description of the features.
    Go on - try a few... Enter 'exit' to end.
    d = .datetime~new
    ........................................... rexxtry.rex on WindowsNT
    say d
    2012-02-17T18:54:16.077000
    ........................................... rexxtry.rex on WindowsNT
    exit

    C:\work.ooRexx\bug.work\dateTime>

    So, rather than use rexxtry, or your dialog program, can you write just a short program and try it to see if you get the error under the Citrix environment.

    Just a simple:

    d = .DateTime~new
    say d

    and show us what you get. I get this with the 4.1.0 release:

    C:\work.ooRexx\bug.work\dateTime>test.rex
    2012-02-17T18:49:16.557000

    C:\work.ooRexx\bug.work\dateTime>rexx -v
    Open Object Rexx Version 4.1.0
    Build date: Dec 5 2010
    Addressing Mode: 64

    I'd like to see what is printed out under Citrix. Since rexxtry fails, this simple program should fail also. But, it would be best to see exactly what happens.

    Thanks.

     
  • Mark Miesfeld
    Mark Miesfeld
    2012-02-18

    Hi Danny,

    I see where the problem probably is. Create a small program with this in it:

    numeric digits 18

    n = time('O')/60000000
    say 'n:' n

    Then run it in your Citrix environment and put the output in this tracker item. Thanks.

     
  • Danny De Wilde
    Danny De Wilde
    2012-02-19

    Dear Marc,

    I have created the requested REXX program and this is the results on the Citrix machine;

    J:>"P:\PCORP\Department\M13 - Finance\M1300 - Finance\OOREXX\20120219-TEST-1.RE
    X"
    4 - numeric digits 18
    6 - parse version ver
    8 - say 'Rexx version : 'ver
    Rexx version : REXX-ooRexx_4.1.0(MT) 6.03 5 Dec 2010
    9 - say 'Windows version : ' SysVersion()
    Windows version : WindowsNT 5.02
    11 - n = time('O') / 60000000
    13 - say 'n:'n
    n:59.9999854166666667
    15 - exit

    The underneath is just to show that even when installed the latest 4.1.0 OOREXX version I remain getting the 'beta' comment.

    J:>"P:\PCORP\Department\M13 - Finance\M1300 - Finance\OOREXX\20120219-TEST-2.RE
    X"
    4 - numeric digits 18
    6 - parse version ver
    8 - say 'Rexx version : 'ver
    Rexx version : REXX-ooRexx_4.1.0(MT) 6.03 5 Dec 2010
    9 - say 'Windows version : ' SysVersion()
    Windows version : WindowsNT 5.02
    11 - t = .datetime~new()
    11 - t = .datetime~new()
    Error 88 running C:\work.ooRexx\wc\main.4.1.0.beta\Win32Rel\CoreClasses.orx line
    3286: Invalid argument
    Error 88.903: Argument offset must be a whole number; found "59.99999375"

    Many thanks for the support. I am always impressed with what people due for the community!

    Kindest regards, Danny

     
  • Mark Miesfeld
    Mark Miesfeld
    2012-02-20

    Hi Danny,

    I should have had you print out the value of time('O') while you were at it.

    The problem is that, internally, when you do .dateTime~new the offset from UTC is calculated using time('O')/60000000. And then the result of that is checked to be a valid whole number.

    In you Citrix environment, as we see, it's not a whole number. Possibly it has something to do with the fact that your desktop is not running locally, but somewhere across a network.

    As far as the beta in the output you see, don't worry about that. That is my own fault. I build the Windows releases and I must not have renamed the 4.1.0 beta directory when I built the release version.

     
  • Rick McGuire
    Rick McGuire
    2012-02-20

    Mark, the Citrix environment is giving a somewhat strange result back from FileTimeToLocalFileTime. The difference appears to be a few ticks shy of being full second amount. I don't know why this is happening, but the following update will ensure that time('o') will always return a value that is an even number of seconds:

    Index: interpreter/platform/windows/TimeSupport.cpp

    --- interpreter/platform/windows/TimeSupport.cpp (revision 7549)
    +++ interpreter/platform/windows/TimeSupport.cpp (working copy)
    @@ -93,6 +93,10 @@

     // ok, we can use this to calculate the timestamp directly
     Date->timeZoneOffset = localTimeStamp - sysTimeStamp;
    
    • // The Citrix environment gives a strange result here that is off by
    • // a few micro seconds. This gives the DateTime class fits, so do an
    • // extra rounding operation here to the nearest second.
    • Date->timeZoneOffset = ((Date->timeZoneOffset + 500000UL) / 1000000UL) + 10
      00000UL;

      SYSTEMTIME localTime;

     
  • Mark Miesfeld
    Mark Miesfeld
    2012-02-20

    Thanks Rick, I saw the commit.

    Is there any reason I shouldn't but it into the bug fix also?

     
1 2 > >> (Page 1 of 2)


Anonymous


Cancel   Add attachments