How to decide begin activity????

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

How to decide begin activity????

Postby Andz1003 » Fri Apr 11, 2008 2:29 pm

Hi,
here goes my question:
I have many activities in my application..
Now,
1) How do I fix which activity should be called first when I start the application?
2) How do I create the .apk (of my whole application)?
3) How do I decide in my .apk the launcher(means the very first) activity to be called when the app is run on emulator?

regards,
Andz
Andz1003
Once Poster
Once Poster
 
Posts: 1
Joined: Fri Apr 11, 2008 2:22 pm

Top

Postby Jesmiatka » Mon Apr 14, 2008 8:29 am

Hi,

1) How do I fix which activity should be called first when I start the application?

You should go to the run options of your project in eclipse (Open run dialog)
When you select your project you will see a dropdown list with all your activities in it where you can select the one that you want to start.

2) How do I create the .apk (of my whole application)?

Right mouse click on your project in your projectbrowser on the left side.
Android Tools > Export application package

3) How do I decide in my .apk the launcher(means the very first) activity to be called when the app is run on emulator?

Go to your AndroidManifest.xml and view it in xml preview.
You will see an activity tag that looks like the following
Syntax: [ Download ] [ Hide ]
Using xml Syntax Highlighting
  1.         <activity android:name=".Start" android:label="@string/app_name">
  2.             <intent-filter>
  3.                 <action android:name="android.intent.action.MAIN" />
  4.                 <category android:name="android.intent.category.LAUNCHER" />
  5.             </intent-filter>
  6.         </activity>
Parsed in 0.001 seconds, using GeSHi 1.0.8.4


You can place that intent-filter in another activity and it will launch with that activity!

Yours sincerely,
Mike
Jesmiatka
Senior Developer
Senior Developer
 
Posts: 164
Joined: Mon Feb 04, 2008 3:37 pm
Location: Netherlands

Re: How to decide begin activity????

Postby beausejour » Wed Apr 16, 2008 11:21 am

Andz1003 wrote:1) How do I fix which activity should be called first when I start the application?


I think he means to change the first activity in the application, so it is in the emulator, not change it in Eclipse. I'm have a similar problem, still can't found a solution.

Good luck
beausejour
Junior Developer
Junior Developer
 
Posts: 18
Joined: Tue Apr 15, 2008 4:04 pm
Location: France

Re: How to decide begin activity????

Postby Jesmiatka » Wed Apr 16, 2008 11:37 am

beausejour wrote:
Andz1003 wrote:1) How do I fix which activity should be called first when I start the application?


I think he means to change the first activity in the application, so it is in the emulator, not change it in Eclipse. I'm have a similar problem, still can't found a solution.

Good luck


@See my response on his 3th question

Yours sincerely,
Mike
Jesmiatka
Senior Developer
Senior Developer
 
Posts: 164
Joined: Mon Feb 04, 2008 3:37 pm
Location: Netherlands

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: No registered users and 9 guests