原創|使用教程|編輯:郝浩|2013-04-03 11:27:27.000|閱讀 3211 次
概述:LaTeX文件格式是一種文本文件格式的文件,標記在TeX語言的LaTeX 2ε衍生語言中,LaTeX是TeX系統的派生格式。
# 界面/圖表報表/文檔/IDE等千款熱門軟控件火熱銷售中 >>
相關鏈接:
LaTeX文件格式是一種文本文件格式的文件,標記在TeX語言的LaTeX 2ε衍生語言中,LaTeX是TeX系統的派生格式。
為了實現這個功能,Aspose.Pdf推出了一個名為LaTeXSaveOptions的類,其中的OutDirectoryPath屬性用于在轉換過程中保存臨時圖片。
下面是將PDF文件轉換為TeX格式的代碼片段
C#
// create Document object Aspose.Pdf.Document doc = new Aspose.Pdf.Document(@"d:\pdftest\Input.pdf"); // instantiate LaTex save option LaTeXSaveOptions saveOptions = new LaTeXSaveOptions(); // specify the output directory string pathToOutputDirectory = @"d:\pdftest\"; // set the output directory path for save option object saveOptions.OutDirectoryPath = pathToOutputDirectory; // specify output file name string outFileName = pathToOutputDirectory + "Output.tex"; // save PDF file into LaTex format doc.Save(outFileName, saveOptions);
VB.NET
' create Document object
Dim doc As Aspose.Pdf.Document = New Aspose.Pdf.Document("d:\pdftest\Input.pdf")
' instantiate LaTex save option            
Dim saveOptions As LaTeXSaveOptions = New LaTeXSaveOptions()
' specify the output directory 
Dim pathToOutputDirectory As String = "d:\pdftest\"
' set the output directory path for save option object
saveOptions.OutDirectoryPath = pathToOutputDirectory
' specify output file name                  
Dim outFileName As String = pathToOutputDirectory + "Output.tex"
' save PDF file into LaTex format            
doc.Save(outFileName, saveOptions)
					本站文章除注明轉載外,均為本站原創或翻譯。歡迎任何形式的轉載,但請務必注明出處、不得修改原文相關鏈接,如果存在內容上的異議請郵件反饋至chenjj@ke049m.cn
文章轉載自:慧都控件網