#!/usr/bin/perl use strict; use warnings; my $input = '/path/to/file'; print "Anzahl Zeilen: "; chomp(my $numberOfFields = ); print "Spalte (Beginn): "; chomp(my $start = ); print "Spalte (Ende): "; chomp(my $stop = ); my $string = ''; open(my $fh,"<$input") or die $!; while(<$fh>){ $string .= substr($_,$start-1,$stop-$start+1); } close $fh; print $string;