If all the lines in your first file look like those in the sample, why not just read the second file (the one with the port numbers) and build the first file from scratch?
I think some more information about the first file (Address1=, etc) may be in order, as I suspect there is much more to this file than has been revealed.
In reply to Re: Need a little help appending lines
by swampyankee
in thread Need a little help appending lines
by perl4ever
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |