datetime_picker_formfield icon indicating copy to clipboard operation
datetime_picker_formfield copied to clipboard

How can I change the datetime value by setState

Open svsno1 opened this issue 5 years ago • 2 comments

I used the initialValue but it only worked the first time. When I setState((){ }) and pass a different value, it doesn't change.

svsno1 avatar Oct 20 '20 04:10 svsno1

I think once you've rendered this, the initialValue cannot be changed (even using setState). I do a workaround by substituting the widget with a Container() first before the value is ready.

aldycool avatar Jul 05 '21 03:07 aldycool

@aldycool would you mind to share some code?

leonardo2204 avatar Dec 10 '21 14:12 leonardo2204