who help me process BIG5?

2005-08-12 Thread sui hm
I have some Excel files by big5 charset. 
I fetch some column from it and save to usmarc file by using MARC::Record, 
but I get nothing. 
It's correct when I process english excel files. 
Is it wrong I use MARC::Record? 
 Please help me.
Thanks.


Check ISBN sub

2005-08-12 Thread sui hm
#!/usr/bin/perl
$s = ''7-5306-3625-1';
$s = &isbn_check($s);

print $ns."\n";

sub isbn_check
{
my($str) = @_;
my($index,$isbn,$ch);

$isbn='';
while($index < length($str))
{
$ch = substr($str,$index,1);
$isbn .= $ch if($ch =~ /[0-9]/);
$index++;
}
return('99') if(length($isbn) < 10 or length($isbn) > 13);
$isbn = substr($isbn,3,10) if(length($isbn) == 13);

my $count = 0;
for($index=0;$index<9;$index++)
{
$ch = substr($isbn,$index,1);
$count=$count + $ch * (10 - $index);
}
$ch = 11 - $count % 11;
$ch = 'X' if($ch == 10);
return($isbn) if($ch eq substr($isbn,9,1));
return('99');
}


Re: Check ISBN sub

2005-08-12 Thread Andy Lester
Please also investigate the Business::ISBN module.

xoa

-- 
Andy Lester => [EMAIL PROTECTED] => www.petdance.com => AIM:petdance