my @lines = (); chomp(@lines); close(Tab); my @tmp = (split(/;/,$lines[0])); my $colu = ($#tmp) +2; my $ro = ($#lines+2); $table->destroy if ($table); $table = $TFrame->Table(-rows=>$ro, -columns=>$colu, -scrollbars=>'se', -fixedrows=>2, -relief=>'raised')->pack(-side=>'top',-anchor=>'nw'); my $r =1; my @Approved =0; foreach my $row (@lines) { my $tmp_l; if ($r>1) { my $data = $r -1; $tmp_l = $table->Label(-text=>$data, -anchor=>'w', %Entry_color, -relief=>"groove"); $table->put($r, 1, $tmp_l); } else { $tmp_l = $table->Label(-text=>"Entry", -anchor=>'w',-background=>'gray', -relief=>"raised"); $table->put($r, 1, $tmp_l); } my $c=2; my @data = (split(/;/,$row)); while ($c <= $colu) { if ($data[$c-2]) { $file_Contant[$r-1][$c-2]=$data[$c-2] ; } else { $file_Contant[$r-1][$c-2]=""; } my $tmp_label; if ($r==1) { $tmp_label = $table->Label(-text=>$data[$c-2], -anchor=>'w',-background=>'gray', -relief=>"raised") ; } $tmp_label = $table->Entry(-textvariable => \$file_Contant[$r-1][$c-2], -width=> 15,%Entry_color, -relief=>"groove") if ($r>1); $table->put($r, $c, $tmp_label); $c++; } $r++; } $table->pack(-fill=>'both',-side=>'top',-anchor=>'nw',-expand=>1); return($table,\@file_Contant) }