I have two text file. Text File A and Text File B

Text File A

T168
T169
T170C0.95F025S58H1000
T176
T250


Text File B

M48
METRIC,LZ
VER,1
FMAT,2
DETECT,ON
%
G93X0Y29
T250
X22Y0
X0Y0
T169
X016038Y11991
X203998Y11991
X203998Y-134725
X216888Y105277
X216Y-108
X003148Y105277
X004Y-108
T168
X216888Y105277
X216Y-108
X003148Y105277
X004Y-108
T170
X11Y1535
T176
X119035Y-126978
X024039Y-119104
X024039Y-120374
X024801Y-117961
X048118Y-124438


I want to copy the text file A and Insert the value In Text File B After the line FMAT,2
So that it wil look like this
M48
METRIC,LZ
VER,1
FMAT,2
T168
T169
T170C0.95F025S58H1000
T176
T250
DETECT,ON
%
G93X0Y29
T250
X22Y0
X0Y0
T169
X016038Y11991
X203998Y11991
X203998Y-134725
X216888Y105277
X216Y-108
X003148Y105277
X004Y-108
T168
X216888Y105277
X216Y-108
X003148Y105277
X004Y-108
T170
X11Y1535
T176
X119035Y-126978
X024039Y-119104
X024039Y-120374
X024801Y-117961
X048118Y-124438


There is any way to do this? Pls Help me

Thank you