Sunday, October 30, 2011

Eclipse changes

I am doing the examples in the book and I have come across some changes with Eclipse. One of the changes is that when you create a new project , the default drawable icon name has changed from icon to ic_launcher. Also a bit of change to the graphical layout interface. All this is minor but is something you have to keep in mind . Technology is changing so fast that a book written just months ago is a bit outdated.

Thursday, October 27, 2011

Short cut keys

I learned a few short cut keys on Eclipse
Ctrl + shift + L- brings up a list of short cut key combinations
Ctrl + shift + / -will create a comment block out of the selected  text
Ctrl + / - will comment out selected line
              or you can type // at the very beginning of the line.

I have started to do the activities in the third book "Android Application Development for dummies". Also downloaded the source code for the book.

On my own I have been trying to create an app that switches from one layout (activity) to another , using a imageButton.

Created two layouts ( main  and secondpage) along with the drawables for both views.
Now I need to create proper registration in the manifest for secondpage ( main is done automatically)
my attempts so far have failed ( I think)


Manifest

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="photo.trans"
      android:versionCode="1"
      android:versionName="1.0">
    <uses-sdk android:minSdkVersion="7" />
    <application android:icon="@drawable/icon"
        android:label="@string/app_name">
        <activity android:name=".PhototransActivity"
                  android:label="@string/app_name">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
<activity android:name=".secondpage">
</activity>
    </application>
</manifest>

I also have failed at modifying the Java file for button.setOnClickListener to switch views.

At one point I was able to remove all errors in Eclipse but when I ran it , it crashed on the Emulator.

Tuesday, October 25, 2011

Hands on

     I did a bit of hands on with Eclipse. I am trying to make a imageButton on main view layout that switches the layout to a second screen and when you touch a imageButton on that screen it switches back to main. Eventually  playing a sound when the second screen is  shown. It compiled correct and no errors in Eclipse but I got a fatal exception error in the emulator. I am not sure but I think I have to register the second activity in the manifest .

Saturday, October 22, 2011

Third book finished

     I finally finished the first read of the book "Android application development for dummies". There is a nice list of open source code at the end of the book and suggestions for some tools to help with writing apps.
     Next is a quick reread  and highlighting important points. Then after that I will go through the examples  step by step. Adding them to Eclipse  for some hands on learning.

Friday, October 14, 2011

Third book

     I am almost finished with the third book  "Android application development for dummies" and I have been taking the second book to work and rereading. I wish I had a photographic memory but since I don't I am having to reread a lot. The worst part is trying to get a better concept of the organization of the structures. I am having a hard time wrapping my head around this. I have a better idea how older programs worked . The old programs were a list of steps, for the most part you knew what was next. This type of programming however is very scattered. I am not sure what happens when. I am not doing enough hands on with eclipse. I am waiting for the "ah ha moment" where I can say I get it. I have had a few of those moments in small ways.


A website you might find useful
http://www.freebookcentre.net/ 

Sunday, October 9, 2011

Importing sample Apps

    An update on importing sample / example apps.
After a bit of googling I found some answers.

These are the steps for importing sample apps.
    1: In Eclipse - File > new > project
           ( new project wizard appears)
    2: Select Android > Android project. Then click next.
           (New Android project window appears)
    3: Check- Create  project from existing samples.
    4: Select build target
           ( Sample list will now be select-able )
    5: Select sample app.
    6: Click finish and the project should be created.

Example Apps

    I tried importing the example apps included with Android  but it says "no projects found". Am I going to have to  create a project and piece it together  from the examples? There has to be a better way...

    I researched the Amazon reader tablet. It looks good  but I need to actually hold one and test  like I did with the B&N Nook. One thing I might have a problem with is the same problem I have with the Apple Ipad, which is being linked with one company.

Just by looking at these sites , it looks like Amazon Fire is a clear winner .Call me old fashion but I would still like to see one in person before deciding. Besides they are not for sale till November it seems.

http://www.amazon.com/Kindle-Fire-Color/dp/B0051VVOB2

http://www.barnesandnoble.com/nookcolor/index.asp#productimg

Saturday, October 1, 2011

Book title says it all

     I was in the Barnes and Noble book store and went through a few books on Android programming . Two were extremely technical and would be good after I learned to make simple apps. I did end up buying another book. "Android application development for dummies" by Donn Felker. I think it will give me a different perspective on  android programming.
     I also looked at the Barnes and Noble nook color , an interesting tablet reader. Before I buy one though I am going to check out the Amazon fire.