Hi, Ok - so I'm running the code below and it's working as I want - unless either of the 2 values being written to the file is 10. (ie unless $num = 8 or 10).
If the value is 10, then I get a couple of warnings about 'use of uninitialised value'. '10' is the only value I've found that exhibits this disgraceful behaviour. Ummmm ...... I'm a little hard pressed to make sense of that ........ something to do with the newline characters or the chomping perhaps ? use warnings; my $file = "try"; my $num = 111111112; open (WRITEB, ">$file") or die "Can't open WRITEB: $!"; binmode WRITEB; print WRITEB pack("I",$num,), "\n"; print WRITEB pack("I",$num + 2), "\n"; close (WRITEB) or die "Can't close WRITEB: $!"; open (READ, "$file") or die "Can't open READ: $!"; binmode READ; while (<READ>) { chomp; $ret = unpack("I", $_); print $ret, "\n"; } close (READ) or die "Can't close READ: $!"; Cheers, Rob _______________________________________________ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs