in reply to Re^2: Scope of a Hash
in thread Scope of a Hash

$ExcelLink = &swOpenExcel( .. 21 variables .. ); sub swOpenExcel { ## I assume ( ... 19 variables ... ) = @_;

That is going to cause you some severe problems.

I would also recomend you rename $rVals, $X, and $Y to something like $rVals_ref, $X_ref, and $Y_ref just to remind you that you are using refs into the future.