I call a subroutine &createExcelChart that passes the hash in as *returnVals.
AAaaah !!! Why do you do this ??
Don't use typeglobs to pass variables around !
It's illegal ! It's punished by The Law (tm) ! It will not work with use strict !
If you want to pass a hash to a function you should use a reference to the hash, i.e :
my %hash = ( 'some' => 'things' ) ;
callFunction( \%hash ) ;
In the function you can for example dereference the hash :
sub callFunction {
my $refhash = shift ;
my %hash = %$refhash ;
...
}