Adding a button which opens another screen

by Justin Anderson » Sat, 26 Jun 2010 01:23:34 GMT


Sponsored Links
 > Thank you for that, so the other screen doing what I want it to do
would be a whole other Java File?
*
The other screen would be a completely separate Activity, which would be a
separate java file.

*> How do I set up a listener on the button as there is already a
listener on the gallery?
*
Look at the documentation for Button... It gives this very example right at
the top of the page:
http://developer.android.com/reference/android/widget/Button.html

*> Sorry if this soulds basic, but I am just learning ;-)*

We all have to start somewhere... Most start with basic. ;-)

----------------------------------------------------------------------
There are only 10 types of people in the world...
Those who know binary and those who don't.
----------------------------------------------------------------------


On Fri, Jun 25, 2010 at 9:35 AM, Justin <justinbrett1...@gmail.com> wrote:

> > >



Adding a button which opens another screen

by Justin Anderson » Tue, 29 Jun 2010 04:35:07 GMT


 irst, make sure you add the new activity to your application's manifest
file. If it is not there you will not be able to launch it.

Second, the Intent class (which is used to start the second activity) has
methods for storing and retrieving certain types of data. You can store the
id in the intent and retrieve it in the second activity to display the
appropriate image.

Hope that helps,
Justin

----------------------------------------------------------------------
There are only 10 types of people in the world...
Those who know binary and those who don't.
----------------------------------------------------------------------


On Sat, Jun 26, 2010 at 9:12 AM, Justin <justinbrett1...@gmail.com> wrote:

>


Sponsored Links


Other Threads

1. webview encoding

i am calling WebView.loadDataWithBaseUrl() and passing utf-8 as the
encoding. when the string renders, some of the characters show as a
block. the string looks fine when i view it in the de{*filter*}.

am i missing some important step here? there doesn't seem to be any
control over this other than the encoding param to loadDataWithBaseUrl
().

thanks.

-- 

2. ADC2 Results?

According to their last email, today is the day.  Has anyone received
news about their ADC2 entry yet?

-- 

3. GLSurfaceView and Key Presses

4. MapView & Directions

5. ADC 2 and Android Market Place Application Error

6. GK : Ho to Skip DroidDo

7. UI Testing in Android Frameworks