Skip to content Skip to sidebar Skip to footer

How To Place A Table Layout Inside The Custom Dialog?

I am creating an android application which presents with custom dialog. In that custom dialog i had placed had placed a table layout generated dynamically.By executing that the dia

Solution 1:

This can be done using setView method, other solution will be to use DialogFragment, overriding onCreateView

EDIT: int first approach you have to keep in mind that you should not call setMessage method, otherwise it will override your custom view

EDIT 2: you can look how to set custom layout for an AlertDialog in this developer page

Solution 2:

Use Dialog instead of AlertDialog, then use setContentView with your layout id.

Post a Comment for "How To Place A Table Layout Inside The Custom Dialog?"