I am developing an app where a user can enter tasks along with the date of completion and time .
For this I created a Modal bottomsheet that opens up when the user clicks add new task.
in that bottomsheet I have a icon to add date along with the task, what I am trying to do is ,I want to open up a calendar when I click that icon so that the user can select a date and I don’t know how to do it.
what i have tried:-
1.Made the calender view visibility gone in the bottom sheet and then set the visiblity to visible on icon click.
2.Created a custom popupwindow that displays the calendar view on the Bottomsheet layout and the mainactivity layout.(popup window didnt work for bottomsheet layout but it worked for mainactivity,issue with this is the calender appears behind the bottomsheet so I have to first close the bottomsheet to interact with the calendar which I dont want.
Please suggest a better solution
thanks