Commit 4933159c authored by Deshini Perera's avatar Deshini Perera

Add new file

parent d643e8cc
from tkinter import *
from Obj_main import *
from tkinter import messagebox
def Scan():
PO_NO = entry1.get()
print(PO_NO)
if len(PO_NO) == 0:
messagebox.showerror('No Po Number Enterd', 'Enter Po Number')
else:
Items = dectection_video_file(True,None,'yolov3-tiny.weights','yolov3-tiny.cfg','coco.names',0.5,0.4)
print('detected Items List is : ', Items)
entry1.delete(0,END)
# declare the window
window = Tk()
# set window title
window.title("Package Recieval for PO's")
# set window width and height
window.configure(width=500, height=300)
# set window background color
window.configure(bg='lightgray')
#Create a canvas object
canvas= Canvas(window, width= 500, height= 300, bg="lightgray")
#Add a text in Canvas
canvas.create_text(100, 50, text="Enter PO Number", fill="black", font=('Helvetica 10'))
#Add Entry Box
entry1 = Entry()
canvas.create_window(230,50, window = entry1)
#Add Button
canvas.create_window(350,50, window = Button(text = 'Scan', command = Scan))
canvas.pack()
window.mainloop()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment