in reply to Problem with OLE Excel

Perl stored the number as an unsigned 2's complement, but something along the way treated it as an signed 2's complement
-30107963 + 2**32 = 4264859333

I don't know who exactly is at fault, and what can be done to fix it.

Update: Forcing the number to be stored as a float internally might do the trick. The following does that:

$x = $x + 0.5 - 0.5;

Replies are listed 'Best First'.
Re^2: Problem with OLE Excel
by Anonymous Monk on Jan 07, 2010 at 22:41 UTC

    He He Ho Ho Hi Hi ... It worked. force Storing it as float. Thank You Teacher :)

Re^2: Problem with OLE Excel
by Anonymous Monk on Jan 07, 2010 at 22:31 UTC

    Thanks ikegami for the suggestion. One more thing just point out .. is that ... data is getting populated properly but at the time of formating the sheet it's gettig changed to negative number.

    Hmmm ... really typical behavior :)