I am converting all my WordPerfect 6.2(for Windows) patient files to Word... There are hundreds of them.
The old filename was limited in the past to 8.3 under DOS and so I used the following encryption.
Example:
John SMITH date of birth 12 November 1933 became
SM331112 (date of Birth in reverse order)
Now, the NEW format for saving as a Word file utilizing long names is going to be
SMITH,JOHN,12 November 1933
much more readable...
I have already converted ALL the WordPerfect Files to Word files (there is a utility in Word for this), so now I have to convert the SM331112 to SMITH,JOHN,12 November 1933.. and needless to say this will be tedious if not done programmatically.
The thought is that I would have to
1. Open the Word directory
2. Get the first occurrence of patient file eg Anne Aardvark 1/1/1985 = AA850101
3 and it should be easy to use substrings to break up the string and ge the date of birth... Uh Oh ! AA does not give me AARDVARK... so that means I need to have to get NAME data from my VFP table
SO FORGET THE ABOVE --->>>>
Change of thought... PLAN 2
So I imagine that the best way is to create a 'tidy' VFP data table with the LASTNAME, FIRSTNAME, DOB and OLD_FILE_NUMBER, and NEW_FILE_NUMBER...
Get Anne Aarvark (or whoever is first) and her file name / date of birth... go to Word processing directory and see if there is an entry for her... (there may be some patients without a letter entries).. If present open it and save it as AARVARK,ANN,01 January 1985... move on to the next one.
Obviously I will need to test the DIrectory with an FOPEN or other (to see if there is an existing Word file present) if so open and save it with a new file name (I want to keep the original) close and move on. It seems that I should not have to OPEN another instance of Word Automation to do this.... I could use dos type commands, or maybe SHELL Execute commands.
I throw this up as my suggested approach... has anyone done anything similar... ?
ALso if anyone knows the best SHELL commands to do the Save As it would be appreciated.
John Fox
The old filename was limited in the past to 8.3 under DOS and so I used the following encryption.
Example:
John SMITH date of birth 12 November 1933 became
SM331112 (date of Birth in reverse order)
Now, the NEW format for saving as a Word file utilizing long names is going to be
SMITH,JOHN,12 November 1933
much more readable...
I have already converted ALL the WordPerfect Files to Word files (there is a utility in Word for this), so now I have to convert the SM331112 to SMITH,JOHN,12 November 1933.. and needless to say this will be tedious if not done programmatically.
The thought is that I would have to
1. Open the Word directory
2. Get the first occurrence of patient file eg Anne Aardvark 1/1/1985 = AA850101
3 and it should be easy to use substrings to break up the string and ge the date of birth... Uh Oh ! AA does not give me AARDVARK... so that means I need to have to get NAME data from my VFP table
SO FORGET THE ABOVE --->>>>
Change of thought... PLAN 2
So I imagine that the best way is to create a 'tidy' VFP data table with the LASTNAME, FIRSTNAME, DOB and OLD_FILE_NUMBER, and NEW_FILE_NUMBER...
Get Anne Aarvark (or whoever is first) and her file name / date of birth... go to Word processing directory and see if there is an entry for her... (there may be some patients without a letter entries).. If present open it and save it as AARVARK,ANN,01 January 1985... move on to the next one.
Obviously I will need to test the DIrectory with an FOPEN or other (to see if there is an existing Word file present) if so open and save it with a new file name (I want to keep the original) close and move on. It seems that I should not have to OPEN another instance of Word Automation to do this.... I could use dos type commands, or maybe SHELL Execute commands.
I throw this up as my suggested approach... has anyone done anything similar... ?
ALso if anyone knows the best SHELL commands to do the Save As it would be appreciated.
John Fox