- Code: Select all
from spire.pdf.common import *
from spire.pdf import *
outputFile = "ToDocx.docx"
inputFile = "./Demos/Data/ToDocx.pdf"
# Load a pdf document
inputfile = inputFile
doc = PdfDocument()
doc.LoadFromFile(inputfile)
# Convert to doc file.
doc.SaveToFile(outputFile, FileFormat.DOCX)
doc.Close()
However, when I check the DOCX file, I observe that every line in the PDF is created as a separate text box in MS Word. Can you please tell if Spire.PDF offers any settings by which I can instruct the converter to use flow mode while creating the DOCX file?
Thanks!