You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched the opened issues and there are no duplicates
Describe the bug
when attempting to set the value of a dropdown, the value after changed ends up empty.
if i print the value after setting it, it does print the value i changed it to.
If i do not attempt to set a value, it does use the text from the selected option as the value and correctly displays that.
Code sample
Code
defdrop_change(e):
print(e.control.value)
e.control.value="show this instead of the actual value"page.update()
print("changed val", e.control.value)#this does print "show this instead of the actual value" but it does not appear in the dropdown after changedupdate_frequency_dropdown=ft.Dropdown(
width=300,
options=[
ft.dropdown.Option("Once a day(default)"),
ft.dropdown.Option("Once a week"),
ft.dropdown.Option("Once a month")
],
label="Update Frequency",
on_change=lambdae: drop_change(e)
)
To reproduce
run the code snippet i shared
Expected behavior
i expect the value set to replace the label in the dropdown after its selected. similar to how the selected option value would replace the label in the dropdown after selected(screenshot).
Screenshots / Videos
Captures
[Upload media here]
Operating System
macOS
Operating system details
latest
Flet version
0.25.2
Regression
I'm not sure / I don't know
Suggestions
No response
Logs
Logs
[Paste your logs here]
Additional details
No response
The text was updated successfully, but these errors were encountered:
Duplicate Check
Describe the bug
when attempting to set the value of a dropdown, the value after changed ends up empty.
if i print the value after setting it, it does print the value i changed it to.
If i do not attempt to set a value, it does use the text from the selected option as the value and correctly displays that.
Code sample
Code
To reproduce
run the code snippet i shared
Expected behavior
i expect the value set to replace the label in the dropdown after its selected. similar to how the selected option value would replace the label in the dropdown after selected(screenshot).
Screenshots / Videos
Captures
[Upload media here]
Operating System
macOS
Operating system details
latest
Flet version
0.25.2
Regression
I'm not sure / I don't know
Suggestions
No response
Logs
Logs
[Paste your logs here]
Additional details
No response
The text was updated successfully, but these errors were encountered: