When I execute the following code in Visual Studio using Python tools and ironpython 2.7 and PyPDF2 v1.20.
i got this error "int() got an unexpected keyword argument 'base' " line 803 in pdf.py
This is my complete code:
import clr
clr.AddReference('System.Drawing')
clr.AddReference('System.Windows.Forms')
from System.Drawing import *
from System.Windows.Forms import *
from PyPDF2 import PdfFileReader
class MyForm(Form):
def __init__(self):
# Create child controls and initialize form
self.Text = "Test Project"
self.Size = Size(600, 500)
path = "F:/Download/RealPython.pdf"
f = open(path)
inputpdf = PdfFileReader(open(path, "rb"))
page = inputpdf.getPage(8)
pagecontent = page.extractText()
display.mediaBox.upperRight = (
display.mediaBox.getUpperRight_x() / 2,
display.mediaBox.getUpperRight_y() / 2
)
Application.EnableVisualStyles()
Application.SetCompatibleTextRenderingDefault(False)
form = MyForm() Application.Run(form)
i got this error "int() got an unexpected keyword argument 'base' " line 803 in pdf.py
Any ideas?