I am using pdftk like this
pdftk template.pdf fill_form /temp/input.fdf output /temp/output.pdf
Now this is working fine
But now i have generated the temporary file instead of /temp/input.fdf with this
myfile = tempfile.NamedTemporaryFile()
myfile.write(fdf)
myfile.seek(0)
myfile.close()
Now i don’t know how can i pass myfile as input to the pdftk
myfile.namewill get you the file path.Note that
tempfiles do not exist afterclose(). From the docs:Source: http://docs.python.org/2/library/tempfile.html