S
Smoolander
At work we receive a txt file with client data (comma delimited) directly
from a system. This file then needs to be used as a mail merge data source.
I am trying to write code to open this data source by first asking the user
to specify the file name (input box), and then open the file and insert
headings into the first row of the file (before client data), as these
headings are used as the mail merge headings.
Currently I am stuck on the code necessary to open the txt file and then to
insert the headings (as a string) into the file in the desired location (line
1) without deleting any of the data in it.
So basically process is
File 30060418.txt is received
User opens word template
Runs macro
Asks for file name
Headings inserted into file
Mail merge reads txt file with headings
Any help on the code would be appreciated.
from a system. This file then needs to be used as a mail merge data source.
I am trying to write code to open this data source by first asking the user
to specify the file name (input box), and then open the file and insert
headings into the first row of the file (before client data), as these
headings are used as the mail merge headings.
Currently I am stuck on the code necessary to open the txt file and then to
insert the headings (as a string) into the file in the desired location (line
1) without deleting any of the data in it.
So basically process is
File 30060418.txt is received
User opens word template
Runs macro
Asks for file name
Headings inserted into file
Mail merge reads txt file with headings
Any help on the code would be appreciated.