2011-04-03 17 views
0

我正在Android中創建一個簡單的應用程序。當我在模擬器中編譯並運行它時,它會顯示這樣的警告框;它是什麼意思?Android中此提醒消息框的意思

對不起,應用程序simplegame(process com.example.simplegame)意外停止。請再試一次!

我總是收到這個警告框?請解釋?

UPDATE:

只是試圖導入圖片在裏面,

import android.app.Activity; 
import android.os.Bundle; 
import android.graphics.Bitmap; 
import android.graphics.BitmapFactory; 
import android.graphics.Canvas; 
import android.graphics.Paint; 
import android.graphics.RectF; 
import android.graphics.drawable.Drawable; 
import android.os.Handler; 



public class SimpleGame extends Activity { 
    /** Called when the activity is first created. */ 
    private Bitmap mBackGroundImage; 
    private Canvas canvas; 
    } 

    @Override 
    public void onCreate(Bundle savedInstanceState) 
    { 
     super.onCreate(savedInstanceState); 
     mBackGroundImage = hBitmapFactory(R.drawable.background1); 
     canvas.drawBitmap(mBackGroundImage, 0, 0,null); 
     setContentView(R.layout.main); 
    } 

    private Bitmap hBitmapFactory(int background1) 
    { 
     // TODO Auto-generated method stub 
     return null; 
    } 
} 

上午newable到android.thats爲什麼得到一些麻煩。

回答

0

您的應用程序崩潰,您的應用程序中必定存在一些異常。請檢查日誌。

+0

。謝謝你的快速回復...我檢查清楚,我沒有在我的日誌中的任何錯誤... – ssss05 2011-04-03 07:13:13

+0

你可以寫幾個代碼,實際上你在應用程序中做什麼。 – 2011-04-03 07:24:59

+0

我已經在上面粘貼了我的代碼,請參閱.... – ssss05 2011-04-03 07:32:58