RE: Piping ifconfig to a text file

2001-10-04 Thread Schoeman, Remco
there is another way to do this $output=`ifconfig -options`;# execute ifconfig with options and save output in $output open (FH ,"> yourfilehere.txt");# open your textfile for writing print FH $output;# print everything ifconfig has printed to the file close FH; #ifconfigs output is still availa

RE: Max Function

2001-10-02 Thread Schoeman, Remco
or you could do it like this $maximum = max (@any_array); #(don't use hashes here) you need to declare the sub max sub max { my $max = shift(@_); for my $item (@_) { $max = $item if $max < $item; } return $max; } this is from the camel book it look prettier to me but t

RE: line end problems - help #2

2001-09-13 Thread Schoeman, Remco
hi ron you are dealing with the difference between dos/win and unix line endings there are plenty of tools to be found on the net to convert unix-text<->dos-text this should get rid of your problems p.s. wordpad.exe should display the file correctly notepad.exe does not(this is the program