3

I have a document in ms word 2010 which we use for documentation purposes on installing some software on our servers.

The document uses <SID> text which indicates to the viewer the text needs to be changed to match whichever server you are working on.

For example:

SQL> !mkdir /oracle/<SID>/mirrlogA/cntrl
SQL> !mv /oracle/<SID>/sapdata1/cntrl/cntrl<SID>.dbf /oracle/<SID>/mirrlogA/cntrl/
SQL> !rm /oracle/<SID>/112_64/dbs/spfile<SID>.ora
SQL> create spfile='/oracle/<SID>/112_64/dbs/spfile<SID>.ora' from pfile='$ORACLE_HOME/dbs/init<SID>.ora';

We have to manually edit each of these or use a Find + Replace for <SID> -> SRS.. Is there a way i can define a document property in place of each of these entries, and then use a macro to prompt the viewer for the SID and it will update all of this automatically?

2 Answers 2

0

Most likely you want to use an ASK field which prompts the user for information and inserts the result into bookmark locations in the document. You will need a macro to make the prompt appear when the document is opened.

There are other ways you may want to go about this, and Greg Maxey has a great page which goes into detail about all of these possible techniques (including using an ASK field) so I suggest to read up on that.

0

There are several options:

  • Totally different: a friend of mine runs a company that works a lot on UNIX platforms. They use LaTeX to generate documentation. LaTeX is a language for typesetting in high quality. On most UNIX and Windows versions it can be installed simply. Output in PDF and other formats.
  • We ourselves use Microsoft Word with Invantive Composition (own product); it allows you to pull data from a database, webservice or alike and put them in tables and fields in Word and in the Word document properties.
  • I've seen an Oracle consultant generating RTF from the UNIX prompt; it is simply to script on UNIX, even when the UNIX flavour has no UNICODE support. RTF can then be mailed using sendmail, transferred using Samba or alike and opened in Word.
  • For simple scenarios with one or few fields and low production volume you can create a custom property in Word (Start -> Document Properties -> Advanced) and insert that using the Insert ribbon. Change value in Document properties, ctrl+a to select all, ctrl+f9 to update the values, voila.
2
  • I did not see your answer when rejecting your edit. Now when I see the answer the edit makes more sense but I would still reject it. The question itself has nothing to do with the tags you added. They are related only to some special examples of multiple possible solutions. Jan 8, 2014 at 8:15
  • Thank you for the explanation. I was not sure when adding the tags on the question whether it is intended to elaborate tags to what options might help the person asking the question. Thanks, I will reflect it in my future assistance. Jan 8, 2014 at 11:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .