mirror of https://github.com/tobya/DocTo
parent
3c31db856d
commit
b018948943
|
@ -83,7 +83,7 @@ _ReSharper*
|
|||
[Ee]xpress
|
||||
#General
|
||||
*.zip
|
||||
test/
|
||||
temp/
|
||||
|
||||
|
||||
|
||||
|
|
BIN
exe/docto.exe
BIN
exe/docto.exe
Binary file not shown.
|
@ -78,6 +78,7 @@ type
|
|||
CHATTY = 5;
|
||||
STANDARD = 1;
|
||||
SILENT = 0;
|
||||
ERRORS = 0;
|
||||
implementation
|
||||
|
||||
|
||||
|
@ -128,6 +129,10 @@ begin
|
|||
Continue := true;
|
||||
end;
|
||||
|
||||
//Ensure directory exists
|
||||
ForceDirectories(ExtractFilePath( OutputFile));
|
||||
|
||||
|
||||
if not Continue then HaltWithError(201, 'Input File, Output File and FileFormat must all be specified');
|
||||
|
||||
|
||||
|
@ -155,12 +160,6 @@ end;
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
procedure TDocumentConverter.HaltWithError(ErrorNo: Integer; Msg: String);
|
||||
begin
|
||||
LogError(Msg);
|
||||
|
@ -336,8 +335,8 @@ end;
|
|||
|
||||
procedure TDocumentConverter.LogError(Msg: String);
|
||||
begin
|
||||
Log('*******************************************');
|
||||
Log('Error: ' + Msg);
|
||||
Log('*******************************************', ERRORS);
|
||||
Log('Error: ' + Msg, ERRORS);
|
||||
end;
|
||||
|
||||
procedure TDocumentConverter.SetInputFile(const Value: String);
|
||||
|
|
|
@ -113,7 +113,7 @@
|
|||
<VersionInfoKeys Name="Comments"/>
|
||||
</VersionInfoKeys>
|
||||
<Parameters>
|
||||
<Parameters Name="RunParams">-L 10 -h</Parameters>
|
||||
<Parameters Name="RunParams">-f "d:\test\word\pie3.doc" -Q -o "d:\test\word\out\pie3y5ts.pdf" </Parameters>
|
||||
</Parameters>
|
||||
<Excluded_Packages>
|
||||
<Excluded_Packages Name="$(BDSBIN)\dcloffice2k150.bpl">Microsoft Office 2000 Sample Automation Server Wrapper Components</Excluded_Packages>
|
||||
|
|
BIN
src/docto.res
BIN
src/docto.res
Binary file not shown.
|
@ -1,10 +1,6 @@
|
|||
wdFormatDOSTextLineBreaks=5
|
||||
wdFormatEncodedText=7
|
||||
wdFormatFilteredHTML=10
|
||||
wdFormatFlatXML=19
|
||||
wdFormatFlatXML=20
|
||||
wdFormatFlatXMLTemplate=21
|
||||
wdFormatFlatXMLTemplateMacroEnabled=22
|
||||
wdFormatOpenDocumentText=23
|
||||
wdFormatHTML=8
|
||||
wdFormatRTF=6
|
||||
|
|
Binary file not shown.
Binary file not shown.
|
@ -0,0 +1,23 @@
|
|||
wdFormatDOSTextLineBreaks txt
|
||||
wdFormatEncodedText txt
|
||||
wdFormatFilteredHTML html
|
||||
wdFormatOpenDocumentText odt
|
||||
wdFormatHTML html
|
||||
wdFormatRTF rtf
|
||||
wdFormatStrictOpenXMLDocument oxd
|
||||
wdFormatTemplate dot
|
||||
wdFormatText txt
|
||||
wdFormatTextLineBreaks txt
|
||||
wdFormatUnicodeText txt
|
||||
wdFormatWebArchive .webarchive
|
||||
wdFormatXML xml
|
||||
wdFormatDocument doc
|
||||
wdFormatDocumentDefault doc
|
||||
wdFormatPDF pdf
|
||||
wdFormatTemplate dot
|
||||
wdFormatXMLDocument xml
|
||||
wdFormatXMLDocumentMacroEnabled xml
|
||||
wdFormatXMLTemplate xml
|
||||
wdFormatXMLTemplateMacroEnabled xml
|
||||
wdFormatXPS xps
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
REM Explaination
|
||||
REM For use of FOR type FOR /? at prompt
|
||||
REM The first part specifies ; lines to be ignored
|
||||
REM I want the first 2 items (delimited by , or [space] on each line from the file specified.
|
||||
REM Variables will be %%i (%%j is created automatically)
|
||||
REM execute docto inserting variables
|
||||
REM %~d0 and %~p0 together give the full directory this batch file is executing in.
|
||||
|
||||
FOR /F "eol=; tokens=1,2* delims=, " %%i in (testdata.txt) do "../exe/docto.exe" -f "%~d0%~p0pie3.doc" -o "%~d0%~p0GeneratedFiles\pie3out_%%i.%%j" -T %%i
|
Loading…
Reference in New Issue