1. Intermediate Android Tutorial – Project Setup

This entry is part 1 of 22 in the series Android-Intermediate

Intermediate Android Tutorial  Intermediate Android Tutorial Project Setup.

Past the noob stage?  It’s time to get busy!

Welcome to the Intermediate Android tutorial series!  We will be learning about amazing Android features, handling data, databases, xml parsing, and more.  However, we will need to setup our project, and that can be somewhat boring, so feel free to just copy the source code below skip the video, unless you have been dying to hear my voice.  This tutorial series will focus on passing data between activities, saving data, remote and local databases, parsing all sorts of stuff from the web, and that’s just the start.  If you haven’t programmed with Android before, or if you think I’m moving a little fast in this tutorial, you should start with the Android basics series.


Project Setup Walkthrough


Intermediate Series Introduction

I’m pretty sure, I’ve laid out what the intermediate Android tutorial series will cover, but just to get into a little more detail, here are some of the things we will learn:

  • Passing data between two activities
  • Saving data within the user’s preferences
  • Loading data from the shared preferences
  • Communicating with a local mySQL lite database
  • Interacting with remote databases
  • XML parsing and working with JSON
  • A bunch of other cool things I can’t think about at the moment

Before we can get into all these exciting tutorials, we will have to set up the base Android project.  I apologize, but that is just the way it has to be, so lets just get it over with.

Here’s the Android source code files (I’ll try to get a downloadable zip soon):
The40SeriesActivity.java

package com.mybringback.theworks;

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

public class The40SeriesActivity extends Activity implements OnClickListener {

	Button width, height, calc;
	TextView area;

	/** Called when the activity is first created. */
	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.main);
		width = (Button) findViewById(R.id.button1);
		height = (Button) findViewById(R.id.button2);
		calc = (Button) findViewById(R.id.button3);
		area = (TextView) findViewById(R.id.textView1);

		width.setOnClickListener(this);
		height.setOnClickListener(this);
		calc.setOnClickListener(this);

	}

	@Override
	public void onClick(View v) {
		// TODO Auto-generated method stub

	}

}

Numbers.java

package com.mybringback.theworks;

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

public class Numbers extends Activity implements OnClickListener {
	EditText number;
	Button sendInfo;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		// TODO Auto-generated method stub
		super.onCreate(savedInstanceState);
		setContentView(R.layout.numbers);
		number = (EditText) findViewById(R.id.editText1);
		sendInfo = (Button) findViewById(R.id.button1);
		sendInfo.setOnClickListener(this);
	}

	@Override
	public void onClick(View v) {
		// TODO Auto-generated method stub

	}
}

Outro

Well, I hope you guys are as excited as I am for the mybringback’s Intermediate Android tutorial series to get rolling.  Make sure you check out the next tutorial where we will start learning things!


Resources

Download links:
I currently don’t have a zip file for this tutorial. If you have watched the video and working project, please zip it and send it to support@mybringback.com


Course Navigation

Next Lesson

Author: trav

I'm just an average guy that love programming.

Share This Post On

5 Comments

  1. Hey Travis,

    I just finished up the beginner series last week and I’m ready for the intermediate series. Thanks for the tutorials, they’ve been great so far. Bring it on!

    -TK

    Post a Reply
  2. Awesome work.. Certainly learnt a lot from these..Could you start something like How to debug an Android Application. How to use Log cat , hierarchy Viewer etc.

    Post a Reply
  3. These tutorials are awesome! :) good job on this site and keep it up. (i found it from the new boston series on youtube lol)

    Post a Reply
  4. These tutorials are awesome. Thanks Travis!

    Post a Reply
  5. Thanks a lot for be so clear!
    {I feel I´d never could learn some of this android´s core stuff at the Oficial site}

    Post a Reply

Submit a Comment

Your email address will not be published. Required fields are marked *


*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>