Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Android Build a Simple Android App (2014) Testing and Debugging Writing to the Log

Ege Yalcin
Ege Yalcin
1,061 Points

2nd Parameter ?

Inside the onCreate() method (after the setContentView() call), log the message "Activity created!" using the Log debug method (remember that it's just one letter). The 1st parameter should be "TreehouseActivity", but use the TAG variable instead of typing it out a second time. The 2nd parameter is the message.

..... ..... ..... ..... Log.d(TAG, ???); ; } }

What is "the message", the log itself ? how do I do that ... :'( ?

4 Answers

Hi Ege,

The message you're supposed to log is "Activity created!"

Amin Lalji
Amin Lalji
1,350 Points

Try something like:

Log.d(TAG, "Activity created!");

The first part is the "tag", the second part (after the comma) is the message you want to log

Hope this helps!

thank you it worked

Ege Yalcin
Ege Yalcin
1,061 Points

I re-watched the video, but there is nothing about that.... it's the last step before learning to publish app on play store which I really want, please help ;(

Andy Sing
Andy Sing
2,190 Points

Which project was that in i have 3 from android ill look back for you

Ege Yalcin
Ege Yalcin
1,061 Points

it's ok now, I don't need, thanks anyway :D