sub del { if (defined $list->curselection) { my $entry = $list->curselection; $list->delete($entry); $varbind = ''; $data = ''; print "INDEX: $index\n"; print "ENTRY: $entry\n"; my $position = ($single - 1); splice @{$hash->{'TRAPS'}->{'TRAP_LIST'}}, $position, $entry; } }