Hi all,
have a query here as being new to Access and VBA it's leaving me dumbfonded.
I have (well actually my boss) has the need to export data from Access to a MS Word document in a formatted manner. OK, so I have started to go down the line of a Word template with unique characters inside it to identify the fields I want replaced (e.g. "<<unique-id>>") and then to use the VBA replace commands to replace the "<<unique-id>>" with the actual value.
OK, so looking through the threads I have been able to start up word, and even replace a single instance of the characetrs to replace, but when I come to loop around obviouly the characetrs I am looking for to replace are now gone!!! So I am obviosuly missing something basic in my understanding , so I wonder if anybody can point me to a good example or some text that explains how to do it.
To give a bit more context, imagine a word.dot template as follows:
--------------------------------------------------------
<< unique-id>> <<title>> <<date>>
--------------------------------------------------------
I want my outcome when I loop throught the records to look something like:
--------------------------------------------------------
000001 A title 01/01/2001
000002 B title 01/02/2002
000003 C titile 01/01/2008
--------------------------------------------------------
You get the idea?
as I said I am really new at this and any help woudl be appretiated.
Oh please note, I am using Access 2000 and Word 2000 (dont know if that matters?).
Your help would be appretiated
have a query here as being new to Access and VBA it's leaving me dumbfonded.
I have (well actually my boss) has the need to export data from Access to a MS Word document in a formatted manner. OK, so I have started to go down the line of a Word template with unique characters inside it to identify the fields I want replaced (e.g. "<<unique-id>>") and then to use the VBA replace commands to replace the "<<unique-id>>" with the actual value.
OK, so looking through the threads I have been able to start up word, and even replace a single instance of the characetrs to replace, but when I come to loop around obviouly the characetrs I am looking for to replace are now gone!!! So I am obviosuly missing something basic in my understanding , so I wonder if anybody can point me to a good example or some text that explains how to do it.
To give a bit more context, imagine a word.dot template as follows:
--------------------------------------------------------
<< unique-id>> <<title>> <<date>>
--------------------------------------------------------
I want my outcome when I loop throught the records to look something like:
--------------------------------------------------------
000001 A title 01/01/2001
000002 B title 01/02/2002
000003 C titile 01/01/2008
--------------------------------------------------------
You get the idea?
as I said I am really new at this and any help woudl be appretiated.
Oh please note, I am using Access 2000 and Word 2000 (dont know if that matters?).
Your help would be appretiated