问题描述
我正在尝试在用户设置的时间出现一个弹出窗口。该窗口会在我预先编码的任何时间出现,并且我必须输入一个值,因为如果没有预先设置的时间,该应用将无法运行。
main.py
class MainApp(App):
hour = NumericProperty(17) # I would receive an error if I was to put None here
minute = 40
def build(self):
schedule.every().day.at(str(self.hour) + ":" + str(self.minute)).do(self.mantraPop_message)
Clock.schedule_interval(lambda dt: schedule.run_pending(),1)
return MainScreen()
kv文件。这是我想在单击数字时发生的事情
LabelButton:
id: six
text: '16'
font_size: 25
text_size: self.width,None
size_hint_y: None
height: self.texture_size[1]
on_release: app.hour = int(six.text)
on_release: print(app.hour)
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)