first android program did not run correctly

Started by
6 comments, last by nickme 10 years, 11 months ago

hi

i started learning android a few days ago, on windows 8 with eclipse. i created the hello world project and when i ran it, the emulator appeared, but it just showed what may be the home screen, not what is shown in the graphical layout in activity_main.xml. according to some website, it suppose to show the hello world in white background. when i clicked the emulator's button, nothing happen. but the clock on the emulator worked, i saw the clock increased when i waited long enough (the clock advanced).

i suspect that that is because i did not set up the eclipse or android correctly but do not know what. i first installed jre instead of jdk (is that the problem?) and then eclipse.

any help is appreciated

Advertisement

IIRC you have to send the app from eclipse to the running emulator, then wait for to install and start it up.

void hurrrrrrrr() {__asm sub [ebp+4],5;}

There are ten kinds of people in this world: those who understand binary and those who don't.

hi khatharr,

thanks for the reply.

what do you mean "send the app from eclipse to the running emulator"? to build and click the run button? can you elaborate?

i waited for like 5 minutes, and nothing changed.

thanks

according to some website

The instructions you should be following are on the Building Your First App page of the Android developer site.

Have you followed those instructions?

If you get stuck on those, which instruction do you get stuck on?

hi frob,

i downloaded the adt bundle in this website:

http://developer.android.com/sdk/installing/bundle.html

but i still get the same result. it is suppose the most easy way to be able to launch android app.

i downloaded the adt bundle in this website:

http://developer.android.com/sdk/installing/bundle.html

but i still get the same result. it is suppose the most easy way to be able to launch android app.

Following the guide step-by-step is the easiest way. That doesn't mean it is a beginner topic, developing for a phone or tablet is hard enough when you are an experienced developer.

Exactly what step are you getting stuck with?

1. Did you install it correctly?

2. Did you create a project with eclipse, setting every value shown in the walkthrough?

3. Did you configure your project with a proper manifest as shown in the walkthrough?

4. Did you create a virtual device with the proper firmware as shown in the walkthrough?

5. Did you properly run the example program using Eclipse as shown in the walkthrough?

If you follow the walkthrough one step at a time it should work out of the box.

hi frob,

1. i assume i install correctly, i do not see any installation error.

2. yes, i created a project. it runs and loads the emulator.

3. i am sorry, i do not know what is proper manifest.

4. yes, i created a virtual device with target name: android 4.2.2

5. as i say in 2. the emulator load and ran but what is shown in the start screen of the emulator is not displaying the "Hello, World!" sad.png

i included the screen shot of the emulator below:

hi

i finally got it to run. what happened was that i have to drag the lock in android start screen to the side to reveal a unlocked icon, then it appeared.

i still having problems with setting up my kindle fire hd 7" to connect with the development computer.

i will yell another post when i can not solve it myself.

thanks everybody.

This topic is closed to new replies.

Advertisement