Hi
I have developed a vb document generator that creates MSWord RTF documents based on certain rules, user inputs and text passages also held in MSWord RTF format. The system selects passages from the text passages and build the output MSWord RTF document.
This has worked perfectly well under MSWord 2000 and MSWord 2003 but when upgraded to MSWord 2007 I have a problem with the page orientation. A copied in MSWord text passage contains a couple of section breaks the first of which changes the orientation from Portrait to Landscape and the last of which changes it back again. When I view the resultant document in the MSWord 2007 version there is no reorientation whatsoever with the total document being in Portrait.
I am at a loss. Any help will be gratefully accepted.
Regards
Mac

The system selects passages from the text passages and build the output MSWord RTF document.

That's probably the source of your problem. You're converting from varying formats. If you just want to preserve the text, convert the RTF source texts to plain text before building your final RTF document.

If you want to try and keep the formatting of the source text, then make convert all text sources to a common RTF version before combining or adding them to the final RTF document.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.