sub build_param_input{ my $params = @_; my $file = SBSTESTFUNCTIONS::get_XML_file_name('FILE'=>"$program_name.pm"); $params = SBSTESTFUNCTIONS::get_vars_hash('FILE'=>$file); print Dumper(\%$params); # testing #output #$VAR1 = { # 'STOP_AFTER' => [ # 'G2155_STOP', # '-1', # undef # ], # 'START_FROM' => [ # 'G2155_START', # '-1', # undef # ], # 'RESPONSE' => [ # 'G2155_RESPONS', # 'G2155_RESPONS', # undef # ], # 'SERVICE' => [ # 'G2155_SERVICE', # 'ENQSYSSV', # undef # ], # 'SHARED' => [ # 'G2155_SHARED', # 'Y', # undef # ] # }; my $count; foreach my $key (keys(%$params)){ $count++; my $name = $lf1->Entry(-textvariable=>$key); $name->insert('e',$key); my $pinput= $lf1->Entry(-textvariable=>$$params{$key}[1]); $pinput->insert('e',$$params{$key}[1]);#Inserts the -1-1 but other values OK. print "$$params{$key}[1]\n"; #to test #Output to stdout #-1 #-1 #G2155_RESPONS #ENQSYSSV #Y $name->grid(-row=>$count, -column=>1); $pinput->grid(-row=>$count, -column=>2); } $count = undef; }