-
Notifications
You must be signed in to change notification settings - Fork 38
Dropdown issue #114
Copy link
Copy link
Open
Description
The problem appeared about a month ago. The same code was working without problems, and I don't know why. The dropdown works fine, but when I try to change the month or year using the month or year buttons, the dropdown menu automatically disappears, leaving me unable to select a month or year.
When I changed the code to this:
and this is the code where i deal with it
if field_type == "date":
date_container = ttk.Frame(section_frame)
date_container.grid(row=r*2+1, column=c, padx=5, pady=(0,10), sticky='we')
entry = CustomDateEntry(
date_container,
textvariable=var,
width=15,
foreground='white',
date_pattern='yyyy-mm-dd',
state="readonly"
)
entry.pack(side='left', fill='x', expand=True)
clear_date(entry)
clear_btn = ttk.Button(
date_container,
text="✕",
width=2,
command=lambda e=entry: clear_date(e)
)
clear_btn.pack(side='right', padx=(5,0))
entry_vars[key] = entry
else:
entry = ttk.Entry(section_frame, textvariable=var, width=22)
entry.grid(row=r*2+1, column=c, padx=5, pady=(0,10))
entry_vars[key] = var
The problem became:
It allows me to select the date the first time without any problems, but when I try to select the date again, the same problem occurs when I try to change the month or year, and I have to select a different cell to solve the problem.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels