Hi Everyone,
I'm new to word VBA but been doing vba with excel and access for a long time. I was given a task and looking for suggestion on how I should code it. Here's what I need.
I have a word document that has information in it. I need to split the information by 20 line segments and place each into a new word document.
Example:
The "source" word document has 88 lines in it. I should end up with 5 word documents: 4 made up of 20 lines each and the 5th with 8 lines in it.
I was thinking about starting off by counting the number of lines within the document and dividing it by 20 so I know how many times I need to create a new document.
From there I would use the extendmode functionality to select text and copy and paste into a new word document.
Would you agree this is the best approach or a feasible approach or is there other functions that I can use?
If you were to go with the approach I'm taking what methods, properties or functions should I use?
Thanks,
Ken
I'm new to word VBA but been doing vba with excel and access for a long time. I was given a task and looking for suggestion on how I should code it. Here's what I need.
I have a word document that has information in it. I need to split the information by 20 line segments and place each into a new word document.
Example:
The "source" word document has 88 lines in it. I should end up with 5 word documents: 4 made up of 20 lines each and the 5th with 8 lines in it.
I was thinking about starting off by counting the number of lines within the document and dividing it by 20 so I know how many times I need to create a new document.
From there I would use the extendmode functionality to select text and copy and paste into a new word document.
Would you agree this is the best approach or a feasible approach or is there other functions that I can use?
If you were to go with the approach I'm taking what methods, properties or functions should I use?
Thanks,
Ken