in reply to Why is this not finding my array value.

For deferencing Line #15:
make $#a1 into $#{$a1}

I'll update on other bits, once I figure out what you're trying to do.

Update: At this point you might as well scroll through the other answers, follow the links from chipmunk's post to learn what you are doing wrong with refs.

You may want to check you Data input. You only use one argument, but you don't check. I'm a bit leary of getting commandline arguments from inside a subroutine that isn't labeled as using that behaviour, but that's a style issue.

Replies are listed 'Best First'.
Re: Re: Why is this not finding my array value.
by c-era (Curate) on Jan 19, 2001 at 00:52 UTC
    $#$a1 will also work, and save you 2 key strokes ; )
    You will also want to change $arg = $a2[$BankCount]; to $arg = $$a2[$BankCount];
Re: Re: Why is this not finding my array value.
by basicdez (Pilgrim) on Jan 19, 2001 at 21:32 UTC
    Got it working now. Thanks for the help.