In this video I’ll show you how to get system information from a computer into your tkinter app.
There’s many reasons you might need to check system info from your tkinter app.
It’s pretty easy, we’ll use the Platform library that comes with Python to do this.
Python Code: sys.py
(Github Code)
from tkinter import * import platform root = Tk() root.title('Codemy.com - System Info!') root.iconbitmap('c:/gui/codemy.ico') root.geometry("600x300") info = f"System: {platform.system()}\n \ User Name: {platform.node()}\n \ Release: {platform.release()}\n \ Version: {platform.version()}\n \ Machine: {platform.machine()}\n \ Processor: {platform.processor()}\n \ Python Version: {platform.python_version()}\n \ " my_label = Label(root, text=info, font=("Helvetica", 14)) my_label.pack(pady=20) root.mainloop()
Add comment