VBA and .rtfs

L

Lee

Is there a way to code into .rtfs? Without having to go
into too many details, the reason why I'm asking this is
that we have a document management program (official
electronic filing system) for all documents that are
created by my employer. This program generates new
documents as .rtfs. This program uses templates which are
called Models. My employer wants me to find out if User
Forms, Modules etc can be used within these .rtf models...
but heck, I do not know where to start. As far as I know,
vba (user forms, modules) cannot be used in .rtfs... HELP
anyone???
 
J

Jonathan West

Hi Lee,

An RTF file cannot have code embedded in it in the way that a doc file can.
The only approach that I can think might work here is if the RTF documents
are based on templates that are stored as conventional Word templates, so
that the macros in the template are available when the RTF file is open in
Word.

To be any more specific than that, I would need more details as to what you
are trying to achieve.
 
L

Lee

We have conventional word templates saved already which
work exactly how we want them to. Unfortunately, staff
save these to the wrong folders and they need to be
entered into our Document Management (DM) program due to
legal requirements. (This is our official filing system).

At the moment, staff save docs to a folder and then our
Records Information staff enter them into the Document
Management program and save it to the correct place.

The DM program has codes that can enter information into
the .rtf file, e.g. who the letter is going to etc but
sometimes, our documents have information that needs to be
inserted at various places through the document, e.g. a
contract name that appears in about 70 places through the
60 page document.

What we want to happen is that authors can created their
own contracts through the DM program and then the VBA has
a fill-in field or user form where the author can type the
contract name once, and it is inserted into the 70 odd
places... Confused??
 
D

Doug Robbins - Word MVP - DELETE UPPERCASE CHARACT

You should set up bookmarks and { REF } fields in the template for that
purpose. I would expect that it would be the staff that create the
documents that would be providing the information via a UserForm to populate
those bookmarks/update the ref fields. The document which will start out as
a Word document, can then be saved as an .RTF file. If there are some rules
that dictate the correct folder for each document, the saving of it as an
RTF file to the correct folder could probably be handled by code in the User
Form.

--
Please post any further questions or followup to the newsgroups for the
benefit of others who may be interested. Unsolicited questions forwarded
directly to me will only be answered on a paid consulting basis.
Hope this helps
Doug Robbins - Word MVP
 

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