Create A Background Image In Android Application Using Android Studio

Introduction

In this blog, you will learn how to develop a background image in an Android Application, using Android Studio.

Requirements

  • Android Studio 2.1.3

Step 1

Open Android Studio 2.1.3, go to file and New Project .

New Project

Step 2

Now, we can change your Application name and afterwards, you can select or click Next button.

New Project

Step 3

Here, we can choose the Target Android devices. Afterwards, you can select the Phone and Tablet.

Now, you can choose Android version. It should be like API:16 Android 4.1(Jelly Bean), API:19 Android 4.4(Kitkat).

Click "Next" button.

New Project

Step 4

Now, we can choose the Blank Activity and click Next button. You can see Main Activity and click "Finish' button.

New Project

New Project

Step 5

Here, open your Application. You can go to Drawable and choose the Show in Explorer. Click now and Drawable opens. We can go to Drawable folder. The folder is empty and you can select any one image. Cut to paste on Drawable folder and automatic is enabled in the image.

New Project

New Project

New Project

New Project

New Project

Step 6

Now, go to toolbox and you can select the ImageView. Image view is added. Go to Text and afterwards, you can write Background image code. It should be like XML code and save all the files.

New Project

New Project

New Project

Step 7

Here, go to Run and select deployment target and after Emulator, it should be like Nexus One API 24 and click OK button.

New Project

Step 8

Now, finally you can get the output.

New Project

New Project

Ebook Download
View all
Learn
View all