How to refresh a "Form"

by Giorgio Torres » Sat, 23 Apr 2011 06:32:48 GMT


Sponsored Links
 Hi, i'm new in android development and I've just completed the tutorial at
developer.android.com.
I'm a J2ME programmer, and I think i have some habits from it.
First of all, it was hard to familiarize with android's UI building way, and
i have some vicious inherited from J2ME's programming way.

I'm trying to build an app which one of the views are refreshed at runtime.
I've created a class "MyForm" that inherits View, and at onCreate method I
setContentView(MyForm). And i'm doing
this with all of my app's "form".

I would like to know android's best way to do what i'm trying.

-- 
Giorgio Prmola F. G. Torres
Graduando em Cincia da Computao
Universidade Federal de Viosa

< http://www.facebook.com/giorgio.torres> ;
< http://br.linkedin.com/in/giorgiotorres> ;
  < http://www.twitter.com/gprimola> ;
< http://www.flickr.com/photos/bygior> ;
< http://www.orkut.com.br/Main #Profile?uid=5773068796254932973>

-- 



Re: How to refresh a "Form"

by TreKing » Tue, 26 Apr 2011 05:12:10 GMT


 




I don't think your question is very clear. However, off the bat I would say
you do not need a "MyForm" class that extends View. You just need a layout
defined in XML that lays out your form and you can set that as the content
for your view. As for "refreshing", most things are automatic (like setting
the text on a TextView) but if you need to force refresh you can look at
invalidate().

-------------------------------------------------------------------------------------------------
TreKing < http://sites.google.com/site/rezmobileapps/treking> ; - Chicago
transit tracking app for Android-powered devices

-- 


Sponsored Links


Other Threads

1. Broadcast on SIM state change

Hi,

Am I right if I say that, there is no broadcast action currently for
the SIM card state changes ?

Thanks,
    Zod.
--~--~---------~--~----~------------~-------~--~----~

2. MediaScannerConnection

MediaScannerConnection provides a way to add a newly created (audio)
file to the phone's mediastore. However, I am wondering how to tell
the mediastore that the application deleted an (audio) file and
therefore is not available anymore ?

--~--~---------~--~----~------------~-------~--~----~

3. VerifyError with Maps Add-ons

4. canvas and android.graphics.camera 3d rotation issue

5. Settings.Secure.getInt got wrong value in AdbSettingsObserver

6. How to prevent Failed Binder Transaction

7. How to get Application Name from the process?