Android Open Source - CSCI567---Workspace Main Activity

From Project

Back to project page CSCI567---Workspace.


The source code is released under:

MIT License

If you think the Android project CSCI567---Workspace listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package csci567.helloworld;
/*from ww  w  . j  a  va2  s .  c  o  m*/
import android.os.Bundle;
import android.view.Menu;
import android.widget.TextView;

public class MainActivity extends Activity {

    protected void onCreate(Bundle savedInstanceState) {
      //Initialize TextView Object to the textview we provided in our layout xml referencing the id we gave it
      TextView txt = (TextView) findViewById(;
      //Replace the text in the textView with the following text.      
      txt.setText("CSCI567 Hello World");

    public boolean onCreateOptionsMenu(Menu menu) {
        // Inflate the menu; this adds items to the action bar if it is present.
        getMenuInflater().inflate(, menu);
        return true;

Java Source Code List