• xxfunxx

    @TutorialDoctor thanks for the links I’m sure I will read them again a few more times. Pretty insightful. Thanks!

    posted in Pythonista read more
  • xxfunxx

    @Phuket2 thanks for the replies! I know I still have tons of reading/learning to do. I’ve been trying to set myself little goals to accomplish. I guess I was just making it more difficult than it is. And it works great with the little bit of code you suggested. Hopefully I’ll get this thing figured out...Thanks so much!

    posted in Pythonista read more
  • xxfunxx

    I am trying to make (what I thought) would be fairly simple GUI with a lighting control switch. It's not actually controlling a light. I just want something that prints to the console that the switch is on or off. I'm extremely new to coding and I just can't figure it out. When I run the code the GUI will appear and print the state of the switch (upon loading) but it will not print if the switch is used after that.

    #Lighting Control Switch
    import ui
    def lightControl(mySwitch):
    toggle.switch1 = mySwitch 
    switch1 = "Off" or "On"
    action_On = False
    print(not action_On)
    action_Off = (not action_On)
    if action_On == True:
    print("Lights On") 
    if action_Off == True:
    print("Lights Off")
    v = ui.load_view()

    I want a switch that indicates to the console that it has been used and whether it is currently on or off.

    No errors are printing and the GUI comes up as it should. Just not the result I want.

    Again, I'm very new to coding and just trying to learn and figure things out. Any help is appreciated, thanks!

    posted in Pythonista read more

Internal error.

Oops! Looks like something went wrong!