in reply to Re^3: Flat File Comment
in thread Flat File Comment

The added code is below. Since the program is actually sharing the master files which look like this:

Expedition:XLT:Power Locks:Power Doors

The code added strips the ":" and then joins only the two fields needed for my side of the program. I am not originating the files another program is doing that.

for (@models) { my @mfields = split /:/; $_ = join ' ' => $mfields[0], $mfields[1]; }

When selected the program only recognizes the first field not the second when joined together creating the following output:

##Expedition
Expedition XLT

Thus not commenting out each Expedition

FIXED!! Using the below code I have no issues splitting the fields and rejoining the fields using split and splice together. Thanks for the suggestions they have been most helpful.

for (@models) { my @mfields = split /:/, $_; $_ = join ( ' ',splice( @mfields, 0, 2)); }