which graphics package are you using (I am assuming tkinter for below ... always supply all needed information about system, version of python, graphics, OS, etc.)
# chkbox = "cb" + '%s' % i # replace with check_text = tkinter.StringVal() self.checkval = tkinter.IntVar() #self.chkbox = Checkbutton(self.frame_content, text = aprlist[i-1]) # replace with: self.chkbox = Checkbutton(self.frame_content, variable=checkval, text = aprlist[i-1], command=self.show_val)You are also going to have to create a function that gets the value of checkval:
def show_val(self, event): print(f"checkval is {self.checkval.get()}")