Android Tutorial & Lessons 4: More XML and reference background

Android Tutorial & Lessons 4: More XML and referencing background Check out the discussion @ my forum for this lesson: What’s up my peepz? (who says peepz anymore?) This lesson will get you up and running, and even if you are an absolute beginner, you can do it. Please subscribe and thumbs up the video and you will be a pro in no time In this lesson you will learn: -A better understanding of XML -Adding a Button -Find coding that even when we don’t remember the exact coding -Basics of the Linear Layout -New XML functions -Adding our picture to the background of our app -Running our program on the emulator This video is the 4 in a web series that I am creating to help you learn Android programming so you can create apps and eventually how to learn to write games for android phones. I want to explain things in a way that everyone can understand, even if you have no experience with Java, XML, C, OpenGL, or as a matter of fact, any other programming language. If you do have a lot of experience with programming, these first videos will be really slow for you, but my goal is to get everyone sprinting, but for now we have learn to crawl. follow me on twitter: /cornboyz
Video Rating: 4 / 5


There are no revisions for this post.

Tags: , , , , ,

25 Responses to “Android Tutorial & Lessons 4: More XML and reference background”

  1. kazam324 August 28, 2011 at 8:35 PM #

    dude you should be a university professor … you teach a lot better than them .. keep it up 😀

  2. akshayaradhya August 28, 2011 at 8:57 PM #

    For all those who are wondering how that pop-up apperars (between 2:08 and 2:40)
    you first need to type android: and then give a 3 seconds pause then choose textStyle(or whatever you want) then put an = sign wand wait for 2 mores seconds
    Vote to keep it on top.

  3. JanOlMajti August 28, 2011 at 9:33 PM #

    When you add jpg file dont do project – clean! Just press F5 to refresh

  4. bistnenutte August 28, 2011 at 10:18 PM #

    whats the diff between this and html?? just curious

  5. MyDollar1 August 28, 2011 at 11:17 PM #

    Amazing tutorial, i successfully completed the application, hopefully i would do the same for my website…Thanks once again

  6. Catarouxx August 28, 2011 at 11:29 PM #

    what key are you using to bring up the quick commands?

  7. robwillful August 28, 2011 at 11:42 PM #

    Here’s a solution to a problem some of you might be having: When you reference the picture in your resource folder, don’t include the extension. So here it would be “@drawable/cornboyz_background” No .jpg at the end.

  8. uidsea August 29, 2011 at 12:12 AM #

    That window doesn’t pop up every time I enter text.

  9. dinesh1051 August 29, 2011 at 12:31 AM #

    Get over all those damn tutorials that kill your time. Here comes a series of comprehensively packed tutorials which are a developer’s delight. These tutorials are “invincible” and he is the undisputed king of android tutorials. We bow down in respect to you sir.

  10. TwizzWTFisWrong August 29, 2011 at 12:47 AM #

    Just a quick question! Why did you change from PNG to JPG for your background image? I know the differences in between the formats but did the PNG image create any problems as a background?
    Thx for a really good tutorial man! Subscribed right away 🙂

  11. TheiWokcLan August 29, 2011 at 12:54 AM #

    How do you get the option menu when you typed android: ????

  12. FFWDEntertainment August 29, 2011 at 1:43 AM #

    You seriously are the mu fuckin man for putting out a solid series like this for free. Keep donating to this man ppl

  13. microzee August 29, 2011 at 2:14 AM #

    hey man love the video tutorials! ok i have a problem too though. i cant run the emulator. i go to the avd manager click the emulator i want to use, and click start. it pops up a dialog in eclipse loading project or something, but the emulator screen thing you showed never pops up. it just has a grey box saying loading in project, then the emulator doesnt pop up. i went to the android sdk folder, then tools, then emulator.exe and it says cannont find freeaddrinfo in ws2_32.dll. that may be prob?

  14. CornboyzAndroid August 29, 2011 at 2:48 AM #

    hey can you send me your project, Right click>Export…> Go into the gen folder, and click file archive and then send it to

  15. 1983Jamar August 29, 2011 at 2:51 AM #

    I named it ha.jpg and keep getting this error error: Error: No resource found that matches the given name (at ‘background’
    with value ‘@drawable/ha.jpg’). But it showis up in my res file.

  16. gordo4584 August 29, 2011 at 3:48 AM #

    Great Videos! I can seem to test my app in the emulator though… I’ve set it up as virtual device and can “start” it from that same menu where it is defined… It will load and have android on it. BUT when I go to Run As there is nothing there, it just says ‘(none applicable)’ … Any ideas?

  17. CornboyzAndroid August 29, 2011 at 4:02 AM #

    @1983Jamar you probably have your image (or a different resource) misnamed. What I mean by that, is that if you have your image named Mypicture.jpg it will delete your project, but if you change it to mypicture.jpg and clean the project it should rebuild your So just make sure all your resources are lowercase and you dont have any crazy symbols or spaces, etc. hope that helps

  18. 1983Jamar August 29, 2011 at 4:44 AM #

    hey evertime i try to reference my pic. i lose my file

  19. siliconsurf August 29, 2011 at 5:11 AM #

    why don’t you just the damn graphical layout tool instead of all this manual xml typing?

  20. siliconsurf August 29, 2011 at 5:13 AM #

    put on your vador helmet

  21. badcc12345678910 August 29, 2011 at 5:45 AM #

    50th Like 🙂

  22. HussainAlmuflahi August 29, 2011 at 6:08 AM #

    No homo.. But i Love you mann… iv been looking for some1 to teach me

  23. MrChrisfranko August 29, 2011 at 6:26 AM #

    jesus christ blow your fuckin nose or something.

  24. Blitzz117 August 29, 2011 at 6:48 AM #

    Why do i get the wrong in the
    It stands R can not be resolved as an variable

  25. MyRsIrl August 29, 2011 at 7:07 AM #


Leave a Reply