VBA macro parse Word line

P

plaintom

Hi,

I'm new to using VBA and am struggling with being able to parse a line
so I can use part of that information in the filename.

What I have are a bunch of Word files (these are doctor's patient
notes) that I need to do two things to:

1.) I need to split these files into individual files.
2.) I need the resulting filename to be have the "MRN number" "Patient
Name" "Date of visit" for the filename. (all of this information is
contained within the first three lines of these files)

For example, each file has the date as the filename and contains every
patient seen by the doctor on that date. I need this to be split so
each patient has their own file with the filename to be similar to:
'1111111 plaintom 113003.doc' and stored in a specific folder.

I have VBA code to split the files into individual patient files but
the filename is 'newdocumentx.doc' where x is a number.

Here is an example of the first three lines in each file:

CLINIC NOTE
PATIENT: LastName, FirstName CLINIC: 1234567
Doctor's Name, M.D. DATE OF VISIT: 5/30/03



Any help would be appreciated. Feel free to email me any suggestions.


Thanks,

plaintom
 
M

Malcolm Smith

Do you have a database behind all of this?

What happens if Miss Sue Someone gets married and changes her name to Mrs
Sue MarriedWoman?

I think that the whole design is a little flaky here. If you want to
discuss this job a little more feel free to contact me via my website.

- Malc
www.dragondrop.com
 

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