How to start Android app development for beginners

How to start Android app development for beginners

Wow, Do you want to know how to start Android app development? I knew it, your answer is yes, but you don’t know-how. This entire post is for you. It will help you to start your Programming adventure as an Android developer.

Let me tell you what are the basic requirements to develipe your first Andoid App. Yes, I know you are exited now. So, Lets see-

  • Android Studio IDE (Integrated Development Environment)
  • SDK (Software Development Kit)
  • JDK (Java Software Development Kit)
  • Virtual device or any Smartphone

Virtual device or any mobile phone to test on the application. So all this takes work to set up now.

I am sure, by after reading this android app development tutorial you can create your first Android app.

Getting Started

First of all, you need to install the Android app development software. So, you need the Android Studio IDE (Integrated Development Environment). So, just click on Download Android Studio.

Loading...

After download, simply install it. This will recommend all those things whatever your system needs for the Android Studio setup.

So, follow all the recommended steps of Android Studio instructions.

Now, you are a beginner. So I'll recommend, you should go there to learn all the basic features of the current version of Android Studio. So check it out the android app development course.

What is Android?

Android is an open-source, customizable mobile operating system created by Google for use on touchscreen devices.

It’s the most popular operating system in use today. While mainly installed on smartphones, it is also in use on other smart devices such as TVs and watches.

Loading...

Getting started with Android development

Now, I am going to tell you something very interesting. Yes, as you can see here is a simple "Hello World" program for you.

So, follow these steps and learn android programming step by step.

Androidmanifest.xml:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.legendblogs.demo">
    <application
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@style/AppTheme">
        <activity android:name="com.legendblogs.demo.MainActivity">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
    </application>
</manifest>

R.layout.activity_main refers to the activity_main.xml file located in the res/layout folder.

How to Start a Blog in 2020 (Beginner’s Guide)

activity_main.xml:

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context="com.legendblogs.demo.MainActivity">
    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:text="Hello World!"
        android:id="@+id/textView"
        android:layout_marginTop="91dp"
        android:layout_alignParentTop="true"
        android:layout_centerHorizontal="true" />
    <Button
        style="?android:attr/buttonStyleSmall"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="Click me"
        android:id="@+id/button"
        android:layout_marginTop="48dp"
        android:layout_below="@+id/textView"
        android:layout_centerHorizontal="true" />
</RelativeLayout>

strings.xml:

<resources>
    <string name="app_name">Legend Blogs Hello world</string>
</resources>

The main activity code is a Java file MainActivity.java.

Loading...

Android get public ip address programmatically

MainActivity.java:

package com.legendblogs.demo;
import android.content.Context;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;
public class MainActivity extends AppCompatActivity {
    private Context context;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        this.context = this;
        Button button_toast = (Button) findViewById(R.id.button);
        button_toast.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Toast.makeText(context,"Welcome to Android Programming",Toast.LENGTH_SHORT).show();
            }
        });
    }
}

These are all the basic files. By using these files you can start your android app development.

Cheers.

Related posts

Write a comment