Home > Software engineering >  AttributeError: 'Checkbutton' object has no attribute 'get'
AttributeError: 'Checkbutton' object has no attribute 'get'

Time:02-10

I am new to Tkinter, and am having an issue when submitting the code. I had an error before involving the reset button, but that has since been fixed, but now the code does not submit, giving the error that is in the title

Here is the code in its entirety https://pastecord.com/ujoxixyhob.dpr

I dont think this will help too much, so here I have isolated it to this one part:

def Submit():
        name = entry_name.get()
        residency = ''
        if rbtnValue.get() == 'intl':
            residency = 'intl'
        if rbtnValue.get() == 'dom':
            residency = 'dom'

        program = comboProgramming.get()
        
        courses = ''
        if cbtnProgramming.get() == 'COMP100':
            courses  = '(COMP100)'
        if cbtnWebDesign.get() == 'COMP213':
            courses  = '\n(COMP213)'
        if cbtnSoftEng.get() == 'COMP120':
            courses  = '\n(COMP120)'
        result = name   '\n'   program   '\n'   residency   '\n'   courses
        messagebox.showinfo(title='Information', message=result)
    

This is where the error says it is. I am hoping to find out the error. Thank you

CodePudding user response:

  •  Tags:  
  • Related