Ummm, I don't think it is an issue with using the "this" keyword...

What does your layout XML file look like?

Thanks,
Justin Anderson
MagouyaWare Developer
http://sites.google.com/site/magouyaware


On Thu, May 12, 2011 at 12:22 PM, subha <[email protected]>wrote:

> just you use  only setContentView(R.layout.main);  it wil work properly
> don't use this.setContentView(R.layout.main);
>
>
> On Thu, May 12, 2011 at 11:47 PM, cmt <[email protected]> wrote:
>
>>
>> I've finally gotten my first Android app to run without any errors,
>> however the TextView that I am using, is not being updated.
>>
>> Here is the code and the last line is where I use setText to update my
>> textview.
>>
>> If someone has any ideas as to why my TextView is not updating, could
>> you please help me out?
>>
>> Thanks!
>>
>> public class HelloAndroid extends Activity {
>>    /** Called when the activity is first created. */
>>        TextView tvIntro;
>>    @Override
>>    public void onCreate(Bundle icicle) {
>>        super.onCreate(icicle);
>>
>>        //setup text views
>>        this.setContentView(R.layout.main);
>>
>>         tvIntro = (TextView)findViewById(R.id.tvIntro);
>>
>>
>>        //display game intro
>>        tvIntro.setText("Text Adventure - By T");
>>
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to [email protected]
>> To unsubscribe from this group, send email to
>> [email protected]
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to