I have a text file that has the following format.
blah
blah
blah
sfpaaa
"Control Unit"
blah
blah
blah
sfpaax
"Heater Control"
blah
blah
sfpaas
"Gas Control"
I would like to write a scipt in VB or VBA for Word that sorts through the blah in the text file and picks out anything that begins with sfp and also picks out the descriptive text beneath.
Ultimately displaying the text in the format below:
sfpaaa "Control Unit"
sfpaax "Heater Control"
sfpaas "Gas Control"
I realise a loop is involved, I thought of storing the text in 2 arrays. One for the spaxxx text and another for the description beneath it then just print the arrays.
In VBA Word I can write a scipt that searches for anything beginning with spa but do not know how I can assign my found text to an array.
Can anyone help?
Many thanks.
Glamdring.