Saving Data from Word Form

S

Steve C

I'd like a general idea of how to go about setting up a Word template from
which I can save data for use in a database. I'm familiar with the "Save
data only for forms" option under File > Save As. I wish to save the data as
a text file for import into another program.

I have tried setting up my form as a simple table containing column headers
in the first row, but I have not had luck capturing the data below them in my
text file. Does my Word form have to be set up a specific way, or am I on
the right track? Thanks!

Steve C
 
J

Jean-Guy Marcil

Steve C was telling us:
Steve C nous racontait que :
I'd like a general idea of how to go about setting up a Word template
from which I can save data for use in a database. I'm familiar with
the "Save data only for forms" option under File > Save As. I wish
to save the data as a text file for import into another program.

I have tried setting up my form as a simple table containing column
headers in the first row, but I have not had luck capturing the data
below them in my text file. Does my Word form have to be set up a
specific way, or am I on the right track? Thanks!

It works for me. When I use that option I get a txt file that is like a csv
file.

Are you sure you protected the form?


--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
(e-mail address removed)
Word MVP site: http://www.word.mvps.org
 
S

Steve C

Yes, I did lock the form. The result I get is:

"Joe","Smith","Wisconsin","Mary","Jones","California","Robert","Brown","Maine"

but my goal was to get the following:

"FirstName","LastName","State"
"Joe","Smith","Wisconsin"
"Mary","Jones","California"
"Robert","Brown","Maine"

The database program that I intend to import this text file to needs to have
it in this format. I created the form in Word due to simplicity for
end-users.
 
J

Jean-Guy Marcil

Steve C was telling us:
Steve C nous racontait que :
Yes, I did lock the form. The result I get is:

"Joe","Smith","Wisconsin","Mary","Jones","California","Robert","Brown","Maine"

but my goal was to get the following:

"FirstName","LastName","State"
"Joe","Smith","Wisconsin"
"Mary","Jones","California"
"Robert","Brown","Maine"

The database program that I intend to import this text file to needs
to have it in this format. I created the form in Word due to
simplicity for end-users.

Sorry, I thought you were not getting anything at all because you wrote:
"(...) but I have not had luck capturing the data below them in my text file
(...)"

Now I see you meant that the data you captured was not organized as you
expected it.

I do not think you can do anything in this case because I do believe this
features was not designed to create a database, but a text file containing
information for one form, i.e. one record; not many records.

But, you still have two options:

1) Since your data seems to be straight forward, you could write a macro to
convert the txt. file to a database by adding a line break every three data
fields (and removing the semi-colon at that location).

2) A much easier avenue to explore is to select the table and paste it in
Excel and save that as a csv file (or txt).

--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
(e-mail address removed)
Word MVP site: http://www.word.mvps.org
 
S

Steve C

My apologies for my lack of clarity. I will take a look at your suggestions
and see which one might work better. Thanks again!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top