How to open a new Activity without closing the Drawer menu?

Asked

Viewed 134 times

0

I have an Activity and in this Activity I have the Drawer menu. How do you call another Activity without the Drawer menu disappearing? I just want to change Activity’s content. I tried to use Fragment but it does not erase what is already on the screen, it inserts a new Activity.

  • You can’t do this... you’ll have to use Ragments to change the content.

  • What do you mean? I don’t understand. @Luc. There are several apps that when you log in you have a "menu" to navigate the app and the Drawer menu. I wanted that space where the menu is changed when I clicked on it without the Drawer menu disappearing. It’s like?

  • If I’m not mistaken, they’re Fragments... Each item in the Drawer menu is a Fragment, so if you click on the 'home' item, open the Fragment, if you click on 'Settings', open the Fragment 'Settings' and so on...

  • 1

    @Luc thank you so much, you’re saving me.

1 answer

-1

Create two files for your new Activity an archive java and the other is one content_name.xml within the content_name.xml you put the command *<include layout="SeuDrawer.xml>"*

RECOMMEND: first do everything you have to do in the content last add the Drawer it disturbs a little kk pq it stays open

Browser other questions tagged

You are not signed in. Login or sign up in order to post.