1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
| from tkinter import Tk, Entry, Button, messagebox
def action():
encrypted_file = entry_encrypted_file.get()
if not encrypted_file:
messagebox.showerror("Erreur"," Zone fichier crypté vide !" )
else:
print(encrypted_file)
root = Tk()
entry_encrypted_file = Entry(root, width=42, bg="navajowhite", font=("Verdana", 12, "bold"))
entry_encrypted_file.place(x=30, y=140)
button1 = Button(root, text=" Action ! ", command=action)
button1.config(
borderwidth=2,
relief="raised",
bg="firebrick1",
width=0,
height=1,
font=("Arial", 14, "bold"),
)
button1.place(x=600, y=150)
root.mainloop() |
Partager