I have a several text files that get updated each month - when they are updated certain lines are missing that I always want adding back to the files - the text I want adding back needs to go into a specific part of the text file(its always the same text that needs adding and same location)
Example of the file -
RAJKOT VARK23 05400228 22.314472 70.785750110.9022800423
HONG KONG VHHH07L12468073 22.310917 113.897967111.1007300022
HONG KONG VHHH07R12468073 22.296675 113.899445109.3007300027
HONG KONG VHHH25L12468253 22.307431 113.932822108.9025300027
HONG KONG VHHH25R12468253 22.321122 113.929639110.9025300022
HONG KONG KAI TAK VHHX31 10930316 22.305500 114.214500109.9031600015
HONG KONG KAI TAK VHHX13 10930136 22.321667 114.196667111.9008800015
PINAR DELRIO-LA COLOMA MULM07 06562075 22.333317 -83.651164000.0007500131
PINAR DELRIO-LA COLOMA MULM25 06562255 22.338892 -83.632686000.0025500131
The text I want adding each time is the lines
HONG KONG KAI TAK VHHX31 10930316 22.305500 114.214500109.9031600015
HONG KONG KAI TAK VHHX13 10930136 22.321667 114.196667111.9008800015
and should always appear beneath the lines HONG KONG (the entries are actually sorted by the lat co-ordintates)
There are some other files that also need similar entries adding the contents of the files do change when they are updated so my addition needs to be just that and not modify any of the other entries.
Can anyone suggest some code I can run each time to make this work?
Thanks in advance
James