I can able to pick the images from gallery and show it up in the UI. I have to delete the one by image after selecting. I done the UI, by showing the red cancel button for each image . But i am unable to delete and show it up un the UI. Please help.
this is my code.
CodePudding user response:
I Done by myself. The issue is i am using bottom sheet to add the images. To delete the images i called removeAtIndex. it works fine. The problem is the bottom sheet does not know the state of the context, so added statefull builder for the bottom sheet. Now it works fine.
CodePudding user response:
Extract the Bottom Sheet Widget to Separate Stateful Widget and it should work. setstate won't work inside that particular Bottom Sheet until it's separated to a Stateful Widget. Give it a try.