Home Uncategorized Learn to make basic android app within 10 minutes using Android Studio

Learn to make basic android app within 10 minutes using Android Studio

Now, I will be making a basic android app from which you can start your proceedings with it.

You will easily get a basic overview of how to make an app.

I want everyone who wants to pursue his career in android will get to know how to start building apps. I will make an android app from the starting so don’t feel that how will it be possible for me to make an app as we are starting from basic app which all can make very easily.

Also Read- crunchify

For learning about android studio, Refer this- Android Studio

What’s in it for me?

  1. Making a hello world android app
  2. Conclusion
  3. FAQs

Making a hello world android app

Step-1

Choosing the empty activity for making a hello world app as shown under-:

activities of android studio

Step-2

  • Choosing the name of your app for example- I am choosing a hello world.
  • Leave the package name section.
  • Choose the language as java/Kotlin (if you know).
  • Click on the finish.
  • Then wait for 3-5 minutes as it will load the home screen after loading executable files.

Step-3

  • Then after loading of all the files, you should first look your manifest files it should look like as under
manifest

It should look like this. Now, I will explain what is there is all in this.

  • In the first line it is the version of XML which we are using in it.
  • In manifest tag, there is a basic URL which is needed for the app (almost the same for every app)
  • Then there is a package name is shown.
  • Now you come in application tag in which the first row is allowed backup which is stated true, that my backup should be taken.
  • Then Icon is shown of our app you can change after downloading the pics and adding to the app.
  • The label is shown as “Hello world” by default, As it is automatically set by a studio, you can change it or remove it if you want.
  • Now it has shown a round icon which is similar to Icon.
  • Now the supports is the basic file of an android studio which should be set true.
  • After its theme is shown which is set for your app, you can change it as you like.
  • Now your activity name is shown. By default Main activity is used, one can change it as he/she is liked.
  • After it there are two files are used for launching and action of the app. It is necessary for running an app.

One must check this file and the additional components if it is missing in it. And one thing more if you add more layout activity then you must check this manifest file as it should be added in the activity section.

Step-4

Now we move towards the layout file (activity.main.xml in this case). It is showing like this-

basic app
  • Now you should remove text view as I will be showing it after pressing the button.
  • Drag the text view and button from the palette section.
  • After dragging the widgets assign them with an Id in attributes section in the right. It is defined as with it we can access views easily further when we need this variable.
  • Here we are using a constraint layout in which constraints are assigned to the left, right, bottom, and top of the screen. Various other layouts are also available which can be used but you will understand other types when you move on.
  • Then you should assign the name of the button in the text if you want to and remove hello world from text view as we will show on clicking of the button.
  • Then one attribute which we will assign is on click attribute. With assigning on click attribute we can use it when we click to show the text what we want.
android studio app

I have shown how I have assigned attributes of the button widget. You can look around and assign the values.

Step-5

Now I am pasting the screenshots of the main activity(Coding Part) with which you will be able to do the task and will describe how I have done it.

code

Here First there is class naming main activity which extends appcompatactivity which ensures the features which we are using should work perfectly and functions are imported directly under it.

First we have to declare button and text view with some name which we want to use here. Then we come into on create a method that is the main body of the app.Function provides the functionalities.

The set content view is establishing your layout with the coded part, which is must you have to take care of it.

Now you have to assign the declare buttons here and link it with Id which you had declared in layout.

Then we will use the onclick method hereby declaring it here and setting the configurations which we want when the user clicks on the button. I have set the text to Hello world so it will show hello world to me when I click on the button.

Step-6

Now we will run the app and will see that our purpose has been accomplished by it or not.

Before running the app you first add emulator in Android Studio by going to the AVD( Android Virtual Device) Manager and click on the virtual device and create a virtual device for yourself in which you can run your app on it.

Now after running the app we will see hello world on emulator after clicking on the button. I am pasting the screenshot here which I have run and gotten as a result.

This is how we make our first app. And now from here on you can start your journey towards becoming an android developer.

Be persistent in this field and also sometimes result in not come out for the first time, then look out the logcat and paste the error on google and you will get the best results from it. Your journey starts from hereon.

The video link is provided under for reference-:

Conclusion-:

Now, I have shown you an example of how a basic android app is made and now start learning from various sources and become a professional app developer.

Also Read- What is Carding

FAQs

Now, I will be taking some questions from my side which beginners may ask and answer them truly to my potential.

1. Is it that much easy developing apps as you have shown above?

I have shown the basic app of how it is built, it doesn’t mean that all apps will be made like it. You have to learn about various activities, layouts, widgets, and software tools embedded in the studio. Then apply it. It is not that much easy as it is looking at it. You have to devote huge time to this then you will become a professional in developing apps. It is just the starting from you can kick start your career. It will become easy if you will enjoy it.

2. How I solve my errors if I found in my app?

You will able to see all errors in the logcat window of the studio. You go there and first read thoroughly what type of error it is. It must be related to java error which we get during java programming. If you find out the mistake thereon that I have made a mistake then correct thereon only. If you are not able to find out the mistake, then copy the error from the logcat window and paste it on google. From there you will find the solution to your error easily. Go and apply it to the studio. And look out stack overflow, they always have a solution to your query.

So, start early and be persistent with patience, this will make you successful in the field of android.

Happy Coding….

RELATED ARTICLES

How an Emergency Line of Credit Can Aid Your Financial Situation?

Whenever there is a financial emergency, people want quick funds to deal with the emergency. In order to cater to this, banks...

Things That Are Harming Your Credit Score

A credit score is a vital parameter to getting the best loan offers. A score of 630 or above is good enough...

The 10 Most Common Mistakes Made When Applying for a Business Loan

A business loan can be extremely useful for your business venture. Whether you are looking to obtain a working capital loan or...

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

How an Emergency Line of Credit Can Aid Your Financial Situation?

Whenever there is a financial emergency, people want quick funds to deal with the emergency. In order to cater to this, banks...

Things That Are Harming Your Credit Score

A credit score is a vital parameter to getting the best loan offers. A score of 630 or above is good enough...

The 10 Most Common Mistakes Made When Applying for a Business Loan

A business loan can be extremely useful for your business venture. Whether you are looking to obtain a working capital loan or...

Top Trading Techniques & Strategies Traders Should Know

There are a number of effective trading tactics you will come across when trading on the financial markets...

Recent Comments