Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8707167
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T03:48:07+00:00 2026-06-13T03:48:07+00:00

I am trying to do inheritance between activities in my application. I want to

  • 0

I am trying to do inheritance between activities in my application.
I want to create “general activity” style for my all application.

For example, this “general activity” includes toolbar and statusbar. I want to show both in each activity in my program.

I wrote the BaseActivity layout like that:

<include layout="@layout/titlebar" />
<!-- Some control that can contain layout -->
<include layout="@layout/statusbar" />

And MainActivity that extends BaseActivity.
I want to insert in code the layout of the MainActivity to the specific space on BaseActivity.

Is it possible to do that? If yes, how can I set the layout of my inheritance activity in specific spase on this BaseActivity?
There is any control that can contain layout?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T03:48:09+00:00Added an answer on June 13, 2026 at 3:48 am

    This can be possible from java side (Note that I didn’t tried yet), here is an example Reusing layout XML and the code behind.

    This is can also be done via layouts.

    You have to make a separate layout (xml) for you toolbar or status bar, and then you have to include in required layout.

    Re-using Layouts will be helpful link and Android Layout Trick #2: Include to Reuse

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I trying to create inheritance so I can have some super classes with general
Working through this step by step guide. I am trying to create the inheritance
I am new to this website and I am trying a simple inheritance example
i've been trying to study for my finals by practicing classes and inheritance, this
I am trying to create a new class Dog that inherits via prototypical inheritance
I'm trying to apply prototyped inheritance to a function in Javascript. It's all pretty
I am trying to create a Single Table Inheritance. However, the Controller must be
I'm trying to create Class Table Inheritance as in ( http://www.castleproject.org/activerecord/documentation/trunk/usersguide/typehierarchy.html ) So let's
Im trying to get my head around javascript inheritance and this code doesnt work
I am trying to set up as has_and_belongs_to_many relationship in my rails application, between

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.