Oct-08-2022, 03:19 PM
Hello,
I have this code:
How do I get those values, so I can print them to the terminal?
Thanks in advance.
I have this code:
import npyscreen class TestApp(npyscreen.NPSApp): def main(self): frame = npyscreen.Form(name = "Set Reminder",) date = frame.add(npyscreen.TitleDateCombo, name = "Date:") AmPm = frame.add(npyscreen.TitleText, name = "AM/PM:",) time = frame.add(npyscreen.TitleSelectOne, max_height=5, value = [1,], name="Choose a Time", values = ["8:00","8:30", "9:00","9:30","10:00","10:30" ,"11:00","11:30","12:00","12:30","1:00","1:30" ,"2:00","2:30","3:00","3:30","4:00","4:30","5:00" ,"5:30","6:00","6:30","7:00","7:30"], scroll_exit=True) # This lets the user interact with the Form. frame.edit() print(time.get_selected_objects()) App = TestApp() App.run()And I want to return/print the: date & AmPm variables.
How do I get those values, so I can print them to the terminal?
Thanks in advance.