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 8183077
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T01:03:14+00:00 2026-06-07T01:03:14+00:00

I have an android project that I want to clone for a second similar

  • 0

I have an android project that I want to “clone” for a second similar project which only differs by one file: it’s sqlite database (assets/mydata.sql).

I’ve turned the source project (reslib) into a library and added it to my clone project’s properties (the source project shows up under “Library Projects” as reslib.jar)

Thing is, I’m not sure how to launch the main activity in the source project. The source project’s main activity sets-up a TabHost. How do I launch into the source project’s main activity from my clone project? I started pasting code into “cloneActivity.java” to fire up the TabHost but then wondered if there was a better way.

  • 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-07T01:03:16+00:00Added an answer on June 7, 2026 at 1:03 am

    Doing this is pretty straight-forward. In the manifest for your dependent project, you need to specify the source project’s activity as the one you want to launch.

    Suppose your source project has package name com.example.source, your dependent project has package name com.example.dependent, and the main activity in your source project is MainActivity.java.

    Then in AndroidManifest.xml in your dependent project, you would have something like the following:

    <application
      android:icon="@drawable/logo" >
      <activity
         android:name="com.example.source.MainActivity" >
         <intent-filter>
             <action android:name="android.intent.action.MAIN" />
             <category android:name="android.intent.category.LAUNCHER" />
         </intent-filter>
      </activity>
    
      <!-- possibly lots more activities and other declarations -->
    
    </application>
    

    Important Notes: In the manifests for both your source project and the dependent project, you must make sure to list all activities, permissions, etc. If later on you add an activity to your source project, you’ll need to remember to add it to the dependent project’s manifest as well.

    Also, you’ll need to copy anything in the source project’s assets directory to the dependent project—and don’t forget to keep that in sync as well. (This is true as of June 2012, I’ve heard that some future version of the Android build tools will likely alleviate this headache.)

    And finally, if you use Eclipse to create the projects, it will create a default layout main.xml. Since resources in the dependent project override resources in the source project, make sure this doesn’t trip you up.

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

Sidebar

Related Questions

I have a problem that I want to reference with another android project, I
Background I have an Android project that has a database with two tables: tbl_question
In my android project I have an image that i want to rotate it
I have a question that I want to debug(not Run) my Android project with
For an Android project I have a number of response tasks that I want
I have an android project containing only login module. I want to integrate this
I have a library-only Android eclipse project (no main class, only library classes) that
I have a working Android tuner project app that I want to use as
I have an Android project that branched into three different applications, app-1 , app-2
I have come across a strange error. I have an Android project that uses

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.