我刚刚制作了一个 Hello Word 应用程序 Android。但是,我得到了这个错误:
Error(3, 19) package android.app does not exist
Error(4, 18) package android.os does not exist
Error(6, 33) cannot find symbol
symbol: class Activity
Error(11, 26)cannot find symbol
symbol: class Bundle
Error(12, 9)cannot find symbol
symbol : variable super
Error(13, 9)cannot find symbol
symbol : method setContentView(int)
Error(10, 5)method does not override or implement a method from a supertype.
当我双击错误时,我得到了这个:
package com.example.Hello;
import android.app.Activity;
import android.os.Bundle;
public class MyActivity extends Activity {
/**
* Called when the activity is first created.
*/
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
}
}