Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,153,344 members, 7,819,212 topics. Date: Monday, 06 May 2024 at 12:49 PM

Learn How To Develop Android Apps With Your Android Phone - Phones (5) - Nairaland

Nairaland Forum / Science/Technology / Phones / Learn How To Develop Android Apps With Your Android Phone (19870 Views)

Learn To Develop Android & Ios Apps Without Writing Codes(free Tutorial) / How To Lock Apps With Fingerprint On Any Infinix Phone Running Android 7 Nougat / How To Lock Your Apps With Password Or Fingerprint On Infinix XUI 2.0 (2) (3) (4)

(1) (2) (3) (4) (5) (6) (7) (8) (9) (Reply) (Go Down)

Re: Learn How To Develop Android Apps With Your Android Phone by Dfinex(f): 10:41pm On Jul 09, 2016
DavidTheGeek:

ASAP.

This tutorial class, though we just started, has started rubbing off on my time & pocket. So i've decided to conclude the tutorial i started here, take a break, do some planning, (thereby giving space for new interested Nairalanders to join and catch up) & proceed in another way.

Dave please how do we send some data across. ....cos this thing, there's no going back o (we must learn it)
Re: Learn How To Develop Android Apps With Your Android Phone by DavidTheGeek: 10:51pm On Jul 09, 2016
folks4luv:

corrected now. the prob was that I didn't modify d \> and >. guess we need to learn what those symbols mean. .
thanks op. now I can go to bed

Good.

/> is a closing tag.
< is an opening tag.
> i'll call this tag "suspension tag"

For better understanding i'll give examples.
<TextView ....... this means you've started writing codes for textview.

When you open a fridge to take water, you should close it when done abi no be so? That's what /> does. It means you've finished writing the code for TextView.

> is used on a Parent to close and accomodate its children. A viewgroup is a parent, while view objects are its children. Example...

<LinearLayout ...... i'm done writing the codes inside here. Close me>
Add children here.
</LinearLayout>
Re: Learn How To Develop Android Apps With Your Android Phone by Dfinex(f): 11:32pm On Jul 09, 2016
DavidTheGeek:


Good.

/> is a closing tag.
< is an opening tag.
> i'll call this tag "suspension tag"

For better understanding i'll give examples.
<TextView ....... this means you've started writing codes for textview.

When you open a fridge to take water, you should close it when done abi no be so? That's what /> does. It means you've finished writing the code for TextView.

> is used on a Parent to close and accomodate its children. A viewgroup is a parent, while view objects are its children. Example...

<LinearLayout ...... i'm done writing the codes inside here. Close me>
Add children here.
</LinearLayout>

Ok...about the background and color codes, are they generated randomly or there are specific codes. like if I want the color something else other than red,?

1 Like

Re: Learn How To Develop Android Apps With Your Android Phone by folks4luv(f): 6:41am On Jul 10, 2016
DavidTheGeek:


Good.

/> is a closing tag.
< is an opening tag.
> i'll call this tag "suspension tag"

For better understanding i'll give examples.
<TextView ....... this means you've started writing codes for textview.

When you open a fridge to take water, you should close it when done abi no be so? That's what /> does. It means you've finished writing the code for TextView.

> is used on a Parent to close and accomodate its children. A viewgroup is a parent, while view objects are its children. Example...

<LinearLayout ...... i'm done writing the codes inside here. Close me>
Add children here.
</LinearLayout>
thanks op. *grab jotter n pen* lol
Re: Learn How To Develop Android Apps With Your Android Phone by Nobody: 10:25am On Jul 10, 2016
DavidTheGeek:

ASAP.

This tutorial class, though we just started, has started rubbing off on my time & pocket. So i've decided to conclude the tutorial i started here, take a break, do some planning, (thereby giving space for new interested Nairalanders to join and catch up) & proceed in another way.
You can restrict it to once or twice a day. Thank you once again.
Re: Learn How To Develop Android Apps With Your Android Phone by Pilate2016(m): 11:33am On Jul 10, 2016
DavidTheGeek:
Before we continue, i'm thinking we should move this thread to a Whatsapp group. It'll be much easier to post and view screenshots (and maybe videos). Also i'll be giving you guys assignment once we get to real work.

What do you guys think?
Please add me if you want to migrate on 08137066183
Re: Learn How To Develop Android Apps With Your Android Phone by Nobody: 11:51am On Jul 10, 2016
Am in too
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 12:01pm On Jul 10, 2016
MY ACCOUNT HAS BEEN BANNED
Oops the mods has banned my account DavidTheGeek for spamming grin

I'll continue tutorials with this account till the ban is lifted.
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 12:15pm On Jul 10, 2016
Dfinex:
Dave please how do we send some data across. ....cos this thing, there's no going back o (we must learn it)
Chai no going back? I have enter one chance of o.

Thanks but i'm turning it down. There's a paid class starting on Whatsapp soon. It's limited, 12 people max. I'll announce the details here when it's set

~DavidTheGeek
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 12:20pm On Jul 10, 2016
Dfinex:
Ok...about the background and color codes, are they generated randomly or there are specific codes. like if I want the color something else other than red,?
The color codes are specific codes. You can get them online.

Here's the site i use... It has a list of different colors nd codes you can choose from... http://www.computerhope.com/htmcolor.htm

Save the page on your browser.

~DavidTheGeek
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 12:27pm On Jul 10, 2016
Reyginus:
You can restrict it to once or twice a day. Thank you once again.
You welcome bro.

I've not seen your work. Are you just reading?

~DavidTheGeek
Re: Learn How To Develop Android Apps With Your Android Phone by Nobody: 12:37pm On Jul 10, 2016
Jinf:

You welcome bro.

I've not seen your work. Are you just reading?

~DavidTheGeek
Still trying to download the app on my 2g snail speed.
Re: Learn How To Develop Android Apps With Your Android Phone by needhelp20: 2:14pm On Jul 10, 2016
I dey follow...





#ineedhelp
Re: Learn How To Develop Android Apps With Your Android Phone by STPEACE10: 2:21pm On Jul 10, 2016
I don't know how to add the button with this new version and I can't find the older version.
Re: Learn How To Develop Android Apps With Your Android Phone by IrradiatoR: 3:12pm On Jul 10, 2016
I'm a newbie in this.. .

following keenly.



I did as instructed and tried changing "me" to "here" and colour too, got this

Re: Learn How To Develop Android Apps With Your Android Phone by Dfinex(f): 3:21pm On Jul 10, 2016
Jinf:

Chai no going back? I have enter one chance of o.

Thanks but i'm turning it down. There's a paid class starting on Whatsapp soon. It's limited, 12 people max. I'll announce the details here when it's set

~DavidTheGeek

lolss...no wahala but u must conclude this benevolence and why are u using another moniker. I but u have like 3.

2 Likes 1 Share

Re: Learn How To Develop Android Apps With Your Android Phone by Dfinex(f): 3:26pm On Jul 10, 2016
Jinf:

The color codes are specific codes. You can get them online.

Here's the site i use... It has a list of different colors nd codes you can choose from... http://www.computerhope.com/htmcolor.htm

Save the page on your browser.

~DavidTheGeek

yeah...most certainly. I have saved it. But u didn't explain the basis for these codes.

by the way happy Sunday.
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 6:24pm On Jul 10, 2016
STPEACE10:
I don't know how to add the button with this new version and I can't find the older version.
There's no difference in the programming code for new aide, old aide, android studio (for pc), it's all the same android programming code.

Follow the instructions.

~DavidTheGeek
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 6:25pm On Jul 10, 2016
IrradiatoR:
I'm a newbie in this.. .

following keenly.



I did as instructed and tried changing "me" to "here" and colour too, got this
Good
~DavidTheGeek

1 Like

Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 6:31pm On Jul 10, 2016
Dfinex:

lolss...no wahala but u must conclude this benevolence and why are u using another moniker. I but u have like 3.
Hehehe you should join in o.

I got banned for spamming... since when did spamming become an offence on Nairaland¿¿¿ grin

~DavidTheGeek
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 6:35pm On Jul 10, 2016
Dfinex:


yeah...most certainly. I have saved it. But u didn't explain the basis for these codes.

by the way happy Sunday.
Happy Sunday to you too. Hope you weren't late to church.

The color codes are called "html color codes".

~DavidTheGeek
Re: Learn How To Develop Android Apps With Your Android Phone by mikky234(m): 7:19pm On Jul 10, 2016
DavidTheGeek:

You're welcome to the thread. Are you following us or you're just passing by?
Definitely following!!!
Re: Learn How To Develop Android Apps With Your Android Phone by Jinf: 7:59pm On Jul 10, 2016
LETS CONTINUE....
We're still working on our app.

Android TextView
A TextView displays text to the user.

The following are the important attributes related to TextView control. You can check Android official documentation for complete list of attributes.

Attribute...
* android:text - display text.
eg android:text="I'm a Text"

* android:id - This is the ID which uniquely identifies the control.
eg android:id="@+id/text"

* android:textSize - Size of the text.
eg android:textSize="10sp"

* android:textStyle - Style (bold, italic) for the text. You can use one or more of the following values separated by '|' eg bold|italic.
eg android:textStyle="bold"

*****************
There are two ways to input a text. It's either you write it directly:
android:text="I'm a text"

OR

Create a string in resources...
<string name="text">I'm a Text</string>

....and reference...
android:text="@string/text"

Check the strings.xml file res/values folder for better understanding.
***********************

Edit your code and replace the hello world text
1ST METHOD...

<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Do not love one, not two. But love the one who loves you TOO.\nDo not love three, not four. But love the one who loves you MORE.\nDo not love five, not six. But love the one who truly STICKS.\nDo not love seven, not eight. But love the one who is willing to WAIT.\nDo not love nine, not ten. But love the one who\'ll love you until the END."
android:textColor="#ff0000" />

*** \n is line break
*** \ before " and ' else an error would occur

2ND METHOD...
In main.xml edit textview

<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/love"
android:textColor="#ff0000" />

In strings.xml file res/values

<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="love">Do not love one, not two. But love the one who loves you TOO.\nDo not love three, not four. But love the one who loves you MORE.\nDo not love five, not six. But love the one who truly STICKS.\nDo not love seven, not eight. But love the one who is willing to WAIT.\nDo not love nine, not ten. But love the one who\'ll love you until the END.</string>
<string name="app_name">MyFirstApp</string>
</resources>

ASSIGNMENT...
Play around with the TextView.
Add style (bold or italic) and increase the text size.

Re: Learn How To Develop Android Apps With Your Android Phone by Darnyel: 8:51pm On Jul 10, 2016
Do not pass me by!
Re: Learn How To Develop Android Apps With Your Android Phone by needhelp20: 8:58pm On Jul 10, 2016
ahhh...no data to download the app just following you guys...



#ineedhelp
Re: Learn How To Develop Android Apps With Your Android Phone by Dfinex(f): 10:31pm On Jul 10, 2016
Jinf:

Hehehe you should join in o.

I got banned for spamming... since when did spamming become an offence on Nairaland¿¿¿ grin

~DavidTheGeek

eyaaa sorry ....no mind those mods e ya. we are solidly behind u......lolss
Re: Learn How To Develop Android Apps With Your Android Phone by yorex2011: 8:27am On Jul 11, 2016
The second method of creating string. i.e using strings.xml is a better practice as it allows for cleaner coding and easy text replacement whenever you want to replace, it is also good when you want your app in anotherllanguage as you can easily just translate everything in ur strings.xml to the new language while maintaining the names of each string.

Imagine walking to a class with 10 boys and 10 girls, the only way to differentiate them is by their names..
That's where ID's come in

Every element in android has a id that uniquely identifies it so that you can do various stuff with it.

You can have 2 buttons of similar desig, its their IDs tthat you'll use to differentiate them and use them to call different actions. Eg a yes button and a no button
Re: Learn How To Develop Android Apps With Your Android Phone by yorex2011: 8:34am On Jul 11, 2016
There's a way in aide where you can click on a item in the xml and it woukd show you all the available attributes that you can work with for that particular element eg button, editText, textView, imageView etc

On the design view you should also be able to move elements around and when you do so you should see an addition line of code that would signify how you positioned it so that you could also learn how to do it by code
Re: Learn How To Develop Android Apps With Your Android Phone by Nobody: 11:02am On Jul 11, 2016
First App. DavidTheGeek, here is it.

(1) (2) (3) (4) (5) (6) (7) (8) (9) (Reply)

Internet Users : Nigeria Ranked #1 In Africa , #10 In The World / Etisalat Sues MTN Over Visafone Acquisition / Google’s Equiano Submarine Cable To Begin Operations In Nigeria By December

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 62
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.