ITP/Server will instruct the appropriate word processor to open the Src document and to save this document to the file 'Dest' in the specified format. ITP/Server will automatically choose the right word processor by inspecting the content of the Src document. The extension of the Src document does not matter. The format of the Src document should be one of the document formats that ITP/Server recognizes, see the description of the Src parameter below.
The format that can be specified for the Dest document depends on the formats that are supported by the word processor that will be used for saving the output. Furthermore, each word processor has its own method for specifying the format of an output file, see the description of the save formats below. Consequently, ITP/Server has a special parameter 'Format' for every supported word processor. Each of these parameters should be used to specify the output format using the method of the corresponding word processor.
After ITP/Server has chosen a particular word processor it will pass the value of the appropriate format parameter to it. If all format parameters are properly set, a single command ConvertDocument can be used to convert files from all supported word processors to a particular format. On the other hand, if you only need to convert Src files of a single word processor, you only need to specify the format parameter of that particular word processor.
Before ITP/Server can use a particular word processor, this word processor must be configured appropriately. Please read the server configuration section of the ITP/Server Manual carefully.
ConvertDocument
Src(<text>)
Dest(<text>)
TimeOut(<number>)
WFWFormat(<number>)
OOoFormat(<text>);
Src: Required.
The word processor document that ITP/Server has to convert. Currently, the following word processor formats are supported: Microsoft Word, OpenOffice.org.
Dest: Required.
The name of the resulting document. Any existing file will be overwritten.
TimeOut: Optional.
The time-out for this command in seconds. If the WordProcessor exceeds this time-out the process is terminated and ITP/Server will report a runtime error.
If this parameter is omitted the appropriate default time-out value for either batch or interactive jobs is used. A time-out value of 0 disables the time-out.
This feature is currently only supported for Microsoft Word.
WFWFormat: Optional (needed if Src is a Microsoft Word document)
The format of the result document if ITP/Server uses Microsoft Word to convert the document. If this parameter is not specified ITP/Server will use the value of the constant WFWFormat. If ITP/Server uses Microsoft Word and this constant is not set, ITP/Server will report a runtime error.
OOoFormat: Optional (needed if Src is a OpenOffice.org document).
The format of the result document if ITP/Server uses OpenOffice.org to convert the document. If this parameter is not specified ITP/Server will use the value of the constant OOoFormat. If ITP/Server uses OpenOffice.org and this constant is not set, ITP/Server will report a runtime error.