on Wed, 04 Sep 2002 16:00:06 GMT, Zanardi2k2 wrote: > Is there something better than: > > $var1=substr($_, 0, 10) > $var2=substr($_, 11, 16) > $var3=...
See perldoc -f pack perldoc -f unpack If you have e.g. the following layout: my $string = "123 456 ABC"; i.e. 9 places for the first field and 10 places for the second field, you can use: my @data = unpack("A9 A10 A*", $string); -- felix -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]