How To Read A PDF File With Tkinter - Python Tkinter GUI Tutorial
Вставка
- Опубліковано 8 лют 2025
- In this video I'll show you how to read a simple PDF file with TKinter.
We'll open the PDF file using PyPDF2, and read it into a Tkinter Text() widget. Reading simple pdf files with Python is pretty easy, it only gets more complicated when the pdf files start using images and input fields and things like that ;-)
▶️ Watch Entire Tkinter Playlist ✅ Subscribe To My UA-cam Channel:
bit.ly/2UFLKgj bit.ly/2IGzvOR
▶️ See More At: ✅ Join My Facebook Group:
Codemy.com bit.ly/2GFmOBz
▶️ Learn to Code at Codemy.com ✅ Buy a Codemy T-Shirt!
Take $30 off with coupon code: youtube1 bit.ly/2VC9WUN
▶️ Get The Code
bit.ly/3fLFQ8p
instead of reading the PDF content, is there a simple way of just displaying the first page of the PDF? for example displaying it on a Frame or Label?
I don't have PC but I still do in phone.using pydroid 3.. I want to master python ... ....😁
good luck!
Thanks sir..🙂
This is actually what i'm searching for 👍🏻 UA-cam is so cool 😀 and you also 😎👍🏻
Ha thanks!
I am a beginner of python.you are awesome man.
Thanks! And welcome to the wonderful world of Python!
PDF viewer and editor , zoom in, out ,select like adobe.is there pdf viewer in python.
Hi Jhon, I cnt read off teh pdf tex,t, I can get to the folder directory but when I call the pdf, the screen is b;ankc, you method may be faulty, by the way I double checked the code many times
Thanks Sir.I was looking for this kind of video for my project
You are most welcome
Hey please tell me how to open multiple pages in this GUI.
These videos are super helpful for beginner programmers, thank you!
I have a problem with texts in Tkinter , maybe you have a quick answer..
In this case app does not extract (or visualize in text box) words that include letters with some diacritic marks (like ā, ž, ņ). Diacritic marks are also displayed as weird symbols if a text from text box is saved to .txt file. I guess it has to do something with encoding?
Your channel is great!
Thanks! Tell your friends ;-)
Is there a way to make it then when an entry box appears, the user can already type without having to click on it?
Entry.focus() " do it just after entry is packed"
Here is your solution
ua-cam.com/video/l1Joyw6UkTo/v-deo.html
@@darshanpanchal3046 thank you!
Good information
Thanks
A big fan of all ur playlists....
Is it possible to add scrollbars to dropdown menus and other widgets.... If it is possible please make a video on that....
Hm, I'm not really sure
please solve this issue: many of the imports are not being recognised by "pylance", in vs code for me. it cant even recognise the PYPDF2 module. How do i solve this annoying issue>
Stop using vscode for python things.
when click the menu how to put the choice from the beginning of line not from center?
Very interresting... What about pdf files with text AND Photos (*.png)
That's the problem .. I can't import May thing in my phone ....it has limit
But still I just wrote down in book 📚
All the code ....
that's a more advanced topic that I may dive into later. But as I said in the video, we won't be discussing that in this video.
@@Codemycom i understand i cant wait for mode
Hey John, thanks for the cool vid! I kept getting this error on the final run: "PdfReadWarning: PdfFileReader stream/file object is not in binary mode. It may not be read correctly. [pdf.py:1079] Exception in Tkinter callback." If anybody else gets it...The fix is: add the parameter mode='rb' to filedialog.askopenfile(), It opens it in binary mode and then PdfFileReader works on the welcome.py file. Go fig' . Thanks again.
Most appreciated, thanks John!
Hey Mr elder,
Can u tell us how we can add spaces in the output
Because whenever there is a line change its eds up like :
HelloWelcome to codemy.comI am John elder
how to make line number for text editor in Tkinter
Can u do, How to read barcode with python in tkinter?
noted
Import "PyPDF2" could not be resolvedPylance
What is pylance?
I'm first ❤️❤️❤️
@MCPRO116 😆😆
woohoo!
@MCPRO116 ha!
Please make some videos about protecting our application please 💛💙🧡
Protecting them from what?
@@Codemycom making an exe file and making a product key for yearly on monthly, sir.
You could have used lambda instead of making the 'clear text ' function
There's always a million ways to do a thing...
Teach us to extract images tables
No clue what that is
is there a way to make a counter within a timer for every time the timer hits zero the counter adds 1
of course
is there a way in tkinter to make a timer that keeps on going and every time it hits zero a counter counts the number of times the timer hits zero
Sure
@@Codemycom can u please make a video explaining how
;-)
:-p