Android Forwarding Sample don't work

by evo » Mon, 13 Apr 2009 12:13:38 GMT

Sponsored Links
I had try some simply code on android. but when run on emulator. the
1st pages are fine, when click the button to second pages. it pop up
error "Sorry - The application Pages (process com.Pages) has stop

here the code:[]

package com.Pages;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class Pages extends Activity
        protected void onCreate(Bundle savedInstanceState)


        // Watch for button clicks.
        Button goButton = (Button)findViewById(;

    private OnClickListener mGoListener = new OnClickListener()
        public void onClick(View v)
            Intent intent = new Intent();
            intent.setClass(Pages.this, loli.class);

an next pages code[]:
package com.Pages;

import android.os.Bundle;

 * Example of removing yourself from the history stack after
forwarding to
 * another activity.
public class loli extends Activity
        protected void onCreate(Bundle savedInstanceState)


I did't find any error on the code, is there any mistake done by me?


Android Forwarding Sample don't work

by Ralf » Mon, 13 Apr 2009 14:06:09 GMT

 Could you look at the logcat output (Eclipse > Windows > Perspective >
DDMS) or "adb logcat" from a shell? There should be a strack trace
that will tell you exactly what crashed.

For example, are you sure that the findViewById does not return null?


Sponsored Links

Android Forwarding Sample don't work

by zooFun » Tue, 14 Apr 2009 01:00:00 GMT

 Did you add your loli Activity into the AndroidManifest.xml?


Android Forwarding Sample don't work

by zhoubo shi » Tue, 14 Apr 2009 10:30:38 GMT

 You can debug your code step by step, Maybe you can find out why.

2009/4/13 zooFun <>


Other Threads

1. Android HAL code debug

Hi guys,

I want to achieve the Camera HAL (, but the sequence of my
method is :
step 1: change the code
step 2: make to generate the
step 3: copy the to my sdcard
step 4: insert my sdcard to my board ,and get the log from adb .

if any wrong , repeat!!

it is very inefficient.

I have spend two days to find better method, but found nothing .If
anybody have the good mothod ,please tell me kindly .




2. ActiveRecord schema for Android

I have to develop an Android application that will have to synchronize
on a regular basis on a distant database, and work offline most of the
Consequently, I need to have the same SQLite database schema in the
application as master database.
The server is developped in Rails ( using ActiveRecord ), and have a
lot of "has_one", "has_many", "belongs_to", "has_and_belongs_to_many"
I've made some research for Android ORM, and I've found this :
 - ORMLite, but it doesn't handle "JOIN ... ON ... ", and doesn't
handle relations
 - android-active-record, but it's still in development
 - activeandroid, but the documentation isn't up to date, so I don't
know if the ActiveRecord schema is respected
 - neodatis, db4o and ammentos, but they're not using SQLite, so
synchronization would be hard
 - jooq, but the ActiveRecord isn't implemented for SQLite...

I'm a little bit disappointed, so all suggestions are welcome !

Louis C.


3. How to delete...?

4. pop on google map

5. Compiling froyo 2.2.2 for sholes

6. Bluetooth file push folder

7. iklan g-slate (alias optimus pad)