Develop Android Apps, Tutorial strings.xml

Next Tutorial
Let's Edit our New App

PREV Page
View All Tutorials

TUTORIALS ll

Learning To Code

AIDE for Creating Android Apps on Android Devices

These tutorials are using AIDE- a SDK coding environment used to code android apps on android devices like tablets and smartphones. AIDE has a free and paid version.

If you have not yet installed AIDE, this guide will help you get started installing it on your tablet or smartphone.
Once you have it installed you can Create Your Simple Android App. Just follow the instructions in this tutorial.

FYI - the intructions for Creating Your Template App are for the most recent version of AIDE. Instruction for the earlier version (original version of AIDE are also included; just scroll down this page to 'Creating Your App - Original Version of AIDE'.

AIDE is available for free download and install at Google Play - you can do a search for AIDE or follow these:
On your tablet Google AIDE link and to their
AIDE website
AIDE has over 2 million downloads and is quite popular with Android App Developers.
Its best feature is that android apps can be coded on a tablet or smartphone; then you can 'build - run - the code, then install' the app on your android device, which makes it great for testing your newly created apps.

Once you build - run your code, and install an app, that app remains on your android device (like any other app you've installed). To open the app, simply click on the apps icon.
When you edit or make changes to your app coding; you build and run the code again,and then install the app again.

Some of AIDE's Many Features

Filebrowser:
Built-in file manager for most common features:
Rename, delete, create file or folder
Please Note: AIDE does not provide for 'moving' files(copy/paste) within the 'AppProjects Hierachy'; so you can use your device File Manager.
For example, to add images into your apps' drawable-hdpi folder; copy the image, then paste it into drawable-hdpi folder but not within AIDE, but by using your device File Manager.

Most smartphones and new tablets have a File Manager included. If not, you can download one from Google Playstore by using the keyword 'File Manager'.

With AIDE, you can create an Android Template java/xml App with a single click (must name your app first).
AIDE is great because of its mobility, you can code on your tablet or cell, on the go.

The newest edition of AIDE has a free and paid version. You can create your app and code with the free version, however, each time you want to 'build and run' your code your presented with the 'nag' screen. I upgraded to the paid to eliminate the nag screen. And, I am not in any way affiliated with AIDE, nor do I make any money from anyone who buys their product.

In my research to 'learn how to create android apps', I found their listing on Google Play Store several years ago. I downloaded AIDE and used the free version for a time, but soon upgraded to the paid version which back then was less than $10. When I got a new smartphone I had to download AIDE once again. This newer edition had the 'nag' screen on the free version. I found it rather annoying so I paid the $20 canadian to eliminate the 'nag' screen.

Android Studio is also compatible with our tutorials; the Java XML codes, and as mentioned, Android Studio is free to use on your desktop or laptop computer. You do need sufficient space and memory to use it; check their website for details. To use Android Studio with our tutorials just choose the Java XML coding language when you create your app. To install Android Studio, just follow the link and download the software executable to your computer, then follow the instructions to install it.

Install AIDE - Create A Simple App - and name it 'Tutorials'

TO INSTALL AIDE ON YOUR TABLET

First, you must goto the Google Playstore, where you can install the AIDE app on your android device
Click here to goto AIDE-for android devices

Click the install link
The app will install on your tablet
(last read AIDE supported android versions 4 and greater)

Open the app

A small screen appears asking you 'What You Want To Do', with several choices;(including Buying Paid Version or Continue with the Free Version)
Just CLick the 'Continue For Free', button, if your not buying the paid version at this time;


If you want to goto the Android Lessons: (Free version - two are free, paid version - some are free; or you can buy lessons for $ monthly) To read the lessons - Now, Choose the category that reads:
Android App Development,
then choose the first lesson.

Naming Your Android App

(For our tutorials, choose this)
You want to 'Create Your First Android Java/xml template Android App, then continue(scroll down) to the menu category and select CODE - for Experts.

Now, the AIDE files and coding editor is opened
Now, from the Left Menu in the coding editor; Choose 'Create New Project';
then choose 'New Android App, (gradle, android, java/xml),
then on the next prompt
type in the name for your app as Tutorials
(this name,Tutorials -app name- is shown with the app icon (green android icon) and is the name you click on to open your app once it has been installed on your android device) and,
type a package name as:com.aac.learnandroid

then click CREATE, it will say, 'creating project',
and then it loads the app files created into AIDE editor for you to view.

At this point your app pages are created and your can view them in the AIDE coding editor; but your app is not yet installed on your tablet. Before we can install it we have to build and run our app.

Build, Run Your App

build run your android app in AIDE, free android tutorials
To build, compile, and RUN our app, we need to:
click the ARROW, (shown in this image circled in green) at top of editor,
then, at the Prompt shown: choose - Continue for Free, and click INSTALL. (If you've purchased AIDE, then there is no NAG screen prompt, you can just click the Arrow on top of page).

It says, 'App installed', then just click OPEN.

Now your app has been installed on your tablet(or smartphone).

To View your newly created 'android app', Look for your app amongst your other tablet apps. Look for the little green android icon, and the app name - Tutorials

Viewing Files in AIDE Coding Editor

How to view files in AIDE

To view files in the editor, choose from the Top Right Menu Dropdown(shown in this image circled in green); then Select VIEW, then FILES; look to the left menu, and there, click on the little orange folder;
Click the orange folder, goto AppProjects
each time you click on it; it goes back to the previous folder; just keep clicking the orange folder a few times until you see at top of it /AppProjects. Your created projects(the apps you made) will be shown in a list like format on the left menu -
as shown in this image.
View your App Projects

Opening Files in The AIDE Editor
To open files in any of your projects, just click on the project name, and keep clicking folders till you get to the file you want to code.

For example: lets say you have created an App named: CodeShapeDrawable; and we want to look at your apps strings.xml file.

First click on the folder app name CodeShapeDrawable,
then click on folder -App,
then click on folder SRC,
then click on folder Main,
then click on folder RES,
then click on folder VALUES,
then click on file strings.xml.
Now your strings.xml file is open in the coding editor. You can edit the code.

To add images to an app you created, just look for the Folder - AppProjects - using your device File Manager. Then click it and look for the App Name. Then click till you get to the res/drawable-hdpi folder to add your image(s).(Note: As mentioned, to copy paste images into the res/drawable-hdpi folder, or res/drawable, use your device file manager as you cannot copy and paste in the AIDE file hierachy)

Each file you open will stay at the top of the code editor(tabs),you can then toggle amongst them.

To create a new project(new app), just choose the Create New Project, also from the left side menu, and then choose New Gradle Java/xml android app


Creating Files and Folders
In AIDE, you can create new files and folders. And, you can rename them.
Create a Folder or File in AIDE, SDK Coding Environment
To create a new file or folder in the AppProject File Hierachy- just click on the Menu selector at top of side menu as shown in this photo circled in green. From the dropdown choose:
Create new File or Folder;
For example: Choose Create New Folder; then,
Type in name of the folder.

Lets assume you need to create the folder named 'raw' for your app project because your adding audio and video files to your app project; like mp4 and wav files. These file types need to be put into the res/raw folder of your app project(res means resources)
They do not go into the res/drawable-hdpi folder. That folder is only for images like jpegs, and pngs.

Once you create your 'raw' folder, you can copy/paste the media files into it using your device File Manager. Then just define the file name in your coded page where required. You do not need to add the file extension in the coded page; just the media name; like this; myvideofile, not myvideofile.mp4.

The same for adding images; in the coded page just define the file name without the extension added.

Files can also be created from within an app project folder;
For example, in the res/layout/ folder; new files can be created by clicking on: Create New xml file. Then, just name your new file like this: Example - myvideopage.xml

Editing Files
Common pages you will edit are: AndroidManifest.xml, main.xml, strings.xml, MainActivity.java. They can be named as you like, except for the AndroidManifest.xml file. Because you created a template android app, it names them this way.
You learned about these pages as you read our Tutorials I - The Coded Pages

Our First Android App
This first app we create is a basic android app,using the 'android template' with Gradle Java XML. It has only one page(one activity); also known as the screenview or pageview. And, it has one simple line of text (Hello World), which is included in the template.

This is ideal when you are first learning to code android apps.
For each of our tutorials, we will learn new codes,(functionalities, features, UI components) that we can add to our simple one page app. And, we will also create new apps as we complete each tutorial. We learn standard coding classes meaning they are compatible across all versions of Android to the newest version 31.

Android Studio

You can also learn to code Android java/xml, on your computer using ANDROID STUDIO, which is free to install and use. And, any files you create using AIDE or Android Studio, are compatible with each other.

So, you can code in Android Studio, then load that coded page into AIDE, to continue coding, then load it back into Android Studio to code. (must be same programming language like java.xml)

You May Like:
Make Sushi Rolls Taste World Wines Flavours and Aromas

Using original AIDE - to Create Your Android Java/xml App

If you had installed AIDE on your android device in previous years(2016,2015, like I did) and didn't update your app, it is possible your using the original version of AIDE, or not the newest version.
If so, that is fine, except when you first open AIDE and navigate to the Create Your App Screen, there are a few differences between the two versions.

With a few exceptions, the coding editor, and navigating it, are the same for both versions. We have already explained some of these in the previous section.


If you have installed AIDE this year, then you are using the latest version; which is easy to know because the newest version has the nag screen asking you if you want to buy the paid version and if not- click, Continue For Free.


In the following guide, you can create your Android Template Java/xml app, with photos and explanation, for the original version of AIDE.
And, Do Read this guide for info on the coded pages; building and running your new App; and navigating the coding editor.


From the folders menu(left menu, or top right choose FILES, then on left menu), click Create New Project Here

Create a Android app, create new project in AIDE, apps for android

Then choose the HELLO WORLD Java/XML template app

Next page as shown in photo here; We Name Your App- there is a:
App Name and a Package Name

how to name your android app package,apk file,android free tutorials
App Name is what is seen in your app`s TextView at top left; and also in your AppProjects listing; and you can name it as you like.
It could be the Theme of your app like EXAMPLE Tutorials It can be edited later, if you want to change it.

Package Name is not seen in your app`s TextView, nor in the AppProjects listing. The com.mycompany.myapp, is used to name your .apk file. The .apk file is the file that contains all your app`s files and is referred to as the apk package or apk.

If you distribute your app to app marketplaces this is the file you use. If you have a domain name you can use it at mycompany, otherwise; name it what you like
We will name it com.androidappcoding.learnandroid


CREATE YOUR SIMPLE APP

Once you've entered your App Name and Package Name info click CREATE


You Have Created An Android App

Now, we will explain the various files in your app and what they do; however, before we do that; we will show you how to RUN your app so you can see what it looks like on your tablet. This is easy to do.

How to Compile and Run Your Newly Created App Files

Click the icon, then choose RUN
First, from the right top of your AIDE screen as shown in this photo, click the icon; then choose RUN.

The app files will compile, dex, build, then sign to create a .APK file for your app.

This apk file then needs to be installed on your tablet, in order for your app to be viewable.
The resulting display will ask you if you want to INSTALL your App

How To Install Your Newly Created Android App, AIDE For Creating Apps on Tablets
Choose INSTALL, and the app will be installed and you will get a confirm that your app has been installed as shown in this photo. Once it has been installed that means your app icon and name is shown in your tablets` apps.

You can click to open the app from here or find your newly installed app`s icon and name we gave it, amongst your tablet`s apps and click that to open your app. Look for the green android icon with the name Tutorials
Confirm Your Android App Has Been Installed,Android App Maker

How to Locate - Open Your New App

All android apps are defined by their icon and app name. Just look at any apps you now have installed on your tablet and you can see this easily.

To locate this apps icon you will look for the android icon that shows on the top left of this tablet photo and the name Tutorials will show with that icon. Double clicking on it will open your app for you. The app should look like the one in this tablet photo.
Creating your Android App: How to view your newly created app
You`ve created your app, and installed it on your device by using RUN and then INSTALL with AIDE. Now, you can learn about the files in your app: what they do, and how to code them to add more functionality to your simple app.

After creating your app you were taken to the AIDE screen, which showed some of your apps files. Now you want to look at all of them and get a better understanding of what they do.

Let`s return to AIDE
Click on the AIDE app icon and you will goto the screen within AIDE.

Review AppProject Files

GOTO
choose icon browse AppProject files
There are various ways you can view your App Projects files:

goto files in AIDE, for creating android apps
Click on ICON top right corner of your screen, choose GOTO
All your files for the APP you just created are shown in the white box dropdown menu
Choose a file to view it
Tap inside the white box to toggle it back
To view it again, click on top right corner of your screen, choose GOTO
Now, view each of your files in your AppProject

Along the top of your screen you can see the files also; click on any of them to view the file in your screen

You can also view files, folders by clicking on these icons on your AIDE screen as shown in these photos:
toggle menu top screen to see files and folders in your android app
show menu to view files in AIDE  AppProject files
If you already read our tutorials; you know some files you DO NOT edit ever! Most of these have the java extension, .java however, you can edit some java files.
DO NOT MODIFY is usually typed across the top of these .java files that should not be edited. They are system created when you created your app and when you edit to update your app, and then RUN your app. They are therefore important in the creation of your app.

As a general rule, .xml files you usually can edit; some .java files can be edited, most cannot be edited.
We do recommend reading our Tutorials (list on this page) to know what each AppProject file does.

Our Newly Created App - Tutorials

Now, let`s look at the apps files. First, we will summarize them; then we can make some additions and changes to practice coding this simple app.

We know this Apps Name is tutorials, , so we will look for that name in the AppProjects folders.
We will double click on Tutorials to view all the apps folders and files:
our newly created simple app named - Tutorial, How To Program Android
The first file to look at is the androidmanifest.xml shown here in the first photo as it is seen in the AppProjects files; and then in the next photo as the actual page with its code.
Please Note: As this app was created from a 'template sample app', these files have been automatically made for us but once you gain knowledge of creating apps you can also create your own to use, although using a pre made example app (also known as a template) and just editing it is much easier- just need to copy-paste-edit your codes.
appProject Files Hierachy
andoridmanifest.xml, for creating android apps

The androidmanifest.xml is the file that contains what your app is about. This file can be edited. The file is necessary to compile, run, and install your app and any of its updates. It resides in the root of your AppProject files.

androidManifest.xml file
What is the android manifest xml file, android app tutorial

You should look to this file to add your app`s icon: android:icon(ic_launcher) and give your app a name: android:label. The icon shows at top of your app view and the app name is next to it. You can change both of these by editing the application element within this file; and the strings.xml file, to change the app name label text.

Other important elements are uses sdk which is the android versions you want your app compatible with; and the intent filter which basically tells your app to goto your first activity. For a simple explanation, the activity is the first page of your app, typically named main.xml, and each android app must have at least one activity, and one java class, typically named, MainActivity.java.

Also in this photo you see the Activity element has .MainActivity - this refers to the file MainActivity.java, one of the few java files you can edit.

mainActivity.java file
What is the mainactivity.java file, android app tutorial

Intent Filter

Basically, the intent filter tells the android system to goto MainActivity , and then from MainActivity.java the android system goes to res/layout/main.xml to get the layout particulars for your screen view and to res/values/strings.xml to get the actual text to display on the screen. If you added images to your textView, the res/drawables is where the system gets them. This summarizes where the android system gathers all the info for your app.

So we know the strings.xml is where you place the text; the drawables is where you place your images, and main.xml, is where you specify the app`s textViews, its appearance, and where you add code for elements like:buttons, and images,and of course the string elements for the text in the app.

The main.xml file has a Linear Layout with a Text View element. A linear layout positions its' elements vertically on the page.
The linear layout defines the activity appearance and how it should show on the screen. Vertical orientation means that when the app is first used the text should show vertically within the screen view.
res/layout/main.xml file
main linear layout page
The TextView element has some layout attributes like width and height; and the element android:text=string/hello means that there is some text to be displayed on this activity. To see what that text is, we know we look at the strings.xml file, and we can find that at /res/values/strings.xml.

The Main.xml file can be edited, and the name can be changed also.


If you do change the name, then the new name must also be coded at the corresponding MainActivity.java file which is at src/com/ androidappcoding/learnandroid /MainActivity.java Read tutorials on main.xml for additional info.

The strings.xml contains all the text for the app; like words, headings, titles. This file can be edited. Read tutorials on strings.
The drawable folders is a place to put your app`s images, and other media types. Typically app images are put in drawable-hdpi folder.
Read tutorials on drawables.

The AppProject Folders

Looking at this next photo of the AppProject Files and Folders: we see the RES folder as being the most often used because this folder has the files: main.xml and strings.xml which you will probably edit often as you make changes and additions to your android app.
Drawables for your app`s images and and media types is also located in RES folder.
The folders of a App Project in Android AIDE, Create Apps in Java XML
The GEN folder, has the files, r.java, and buildconfig.java: neither of these should be modified. They are created when you compile and run your app.

The LIBS folder, contains files for your libraries, code from external sources that helps to build your app. If using a template to create your app, these are created for you.

The GIT has java files and external sources for creating files. You may code these once you become an experienced programmer.

The BIN folder is where you can find your app apk file. The apk file is like a desktop computer exe file - but only compatible with android devices. It contains all the components of your app. It is in a compressed format, and when installed it uncompresses itself.

The apk file is important as it is the file you need to use to distribute your app to market places like Google and Amazon.
You can copy - paste the apk file to - from the BIN folder. Use your tablet`s file manager to copy it, as you cannot copy or paste a file from within AIDE file hierachy.

You can also use an APK Analyzer Tool to find, view, share your apks from your device. To do so, just browse for your App Name (name you gave it when you created it) once you open the APK Analyzer Tool.
Select your app name, and you can see all the info about your app including the package name, and the signing key certificate, which is just a long number including letters.
Also view date is was created, and numerous other details that you might want or require when marketing or optimizing your app.
APK Analyzers can be downloaded for free at Google Playstore, and Amazon. Most are free with some in app advertising.
And, most allow for Sharing apk to others, like to your Cloud; or just to import it to your device.

Your app apk file can also be used to let users download your app from your website, blog, or social media posts.

These common folders and files - RES - values(strings.xml) , layout(main.xml), drawables(for images),SRC (mainactivity.java), and the androidmanifest.xml; will the most often edited files for any app you create.

Now that you have created a simple "template android app' and read the basics of what each app file does; you can now begin to add to your app and edit your app`s textView. Then, you can add more functionality to your app: things like buttons, images, a second page;(activity) .

If you have read our Tutorials; then you are somewhat familiar with the code classes and the elements - and their attributes that are available for use in your app`s textView.
NEXT Page - Adding Styles To The App Named Tutorials




If you liked our free Android App Tutorial Give Us A Social Mention Share This Page




AIDE for creating Android Apps on your tablet or cell phone(android).
Free and Paid.
GoTo Aide

ANDROID STUDIO - for creating Android Apps on your desktop computer.
Free to Install and Use
Learn more - Android Studio

The Java XML files we code(example codes) and the Android Apps we create in our Free Tutorials are compatible with Android Studio and AIDE. Just choose Java XML as your Programming Language.




About Our Images
All images on this page are copyrighted material. You can use the images included with each tutorial for the purpose of creating your android app. These images are not to be distributed or sold.



AndroidAppCoding.com
All Rights Reserved