Answer the question
In order to leave comments, you need to log in
Is it possible to pass the value of a variable to the shutdown -t attribute using the os module?
def shutdown():
hour=int(shutdownEntry_h.get())
min=int(shutdownEntry_m.get())
sec=int(shutdownEntry_s.get())
if min!=""and hour!=""and sec!="":
in_min_h=hour*60
in_min_m=min*1
in_min_s=sec/60
min_sum=in_min_h+in_min_m+in_min_s
print(min_sum)
os.system("shutdown -s -t min_sum")
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question