Tutorials & Examples

Android development starts here. Please do not post questions in this sub-forum.

[B4X] Smart String Literal

The "smart string" literal is a more powerful version of the standard string literal.
It has three advantages:
  1. Supports multi-line strings.
  2. No need to escape quotes.
  3. Supports string...
 
Last edited:

ABWearOS Library 1.0

Last edited:

File Choose

Quickly create a File_Chooser, and choose any type of File without any Library.


Download code Here
 

Get resolution of video from file

MediaMetadataRetriever:
    Dim metaRetriver As JavaObject
    metaRetriver.InitializeNewInstance("android.media.MediaMetadataRetriever", Null)
    metaRetriver.RunMethod("setDataSource"...
 
Last edited:

Flow chart to help choose folder

This flow chart will help you choose the folder in all kinds of different cases:

1626940622208.png


There were reasons to use other folders in the past. Those reasons are no longer relevant, mainly...
 
Last edited:

[B4X] Builder command line script

Hi all,

Attached are txt files that are really windows .bat files. These are to help with building multiple libraries.

If you are building a large project with multiple libraries it can get hard...
 

Attachments

  • B4AExampleCompileScript.txt
    4.4 KB · Views: 384
  • B4JExampleCompileScript.txt
    4.4 KB · Views: 344

Apprendre à utiliser les Vues B4A - Partie 2 (Learn to use B4A views - Part 2)

Learn to use Design Views in B4A (Learn to use Design Views in B4A)


 

Receiving shared images from other apps

This example shows how to create an app that can act as a sharing target. It will be listed in the list of apps that show when the user shares an image.

The first step is to add an intent filter...
 

Read QR code from file

Hello team,

If you want to scan QR code from a file (Bitmap or pdf) you can try this code:
You need PDFium and Barcode Reader

B4X:
'Code module
'Subs in this code module will be...
 

Make sure you are enrolled in new 15% Play Store Fee

If you receive an email from google announcing the new 15% service fee (instead of 30%) that looks like this:

Google-Notice.png


I was a little confused of why do I have to create a group if I only...
 
Last edited:

[B4X] [B4XPages] Menu badges

1628579674728.png


This is a B4i + B4A example. It adds a dynamic badge to the menu icon. It also shows how to update menu items at runtime.

Don't miss:
1. B4A - theme settings in manifest editor.
2...
 

Attachments

  • Project.zip
    16.6 KB · Views: 1,635

Calculation of Distance in Km between two points on MapFragment

Hi I share a simple solution to calculate the distance in km between two points on MapFragment. I hope it will be of help to anyone who works with the GoogleMaps v2.50 library.

The coordinates...
 

Compilation time and auto-increment build version

This tutorial demonstrates how the custom build action feature can be used to add a file during compilation with the compilation time and an automatic version number that is incremented with every...
 

Attachments

  • compiletime.jar
    81.9 KB · Views: 939
Last edited:

Core Programming - Chain of Several Programmer

Core Programming Is a group chain of Programmer working on the development of new Features.

Here is a channel to teach newbies how to get started working with B4A and it is a channel to...
 

Custom Context Menu for Text Selection

SS-2017-07-13_10.43.43.png


This example uses inline Java with JavaObject to allow creating custom context menus when the user selects text.

To use...
 

Attachments

  • CustomContextMenu.zip
    8.4 KB · Views: 1,516

Convert collections to json and vice versa

The JSON libraries, which are internal libraries, were updated. The new version is 1.20.

There is a new JSON type which is used to convert maps or lists to json strings and vice versa, using the...
 
Last edited:

[B4X] Cross platform Editable B4XTable + Form Example

SS-2019-04-11_15.50.04.png


This example demonstrates several things:
  • Cross platform code and files, similar to the way XUI2D games are...
 

Attachments

  • Project.zip
    194.2 KB · Views: 1,962
Last edited:

💡 [B4X] Using JSON generator, 5 simple examples - Newer developers

Hello all,
Well here we are with a simple example on how to use the JSON generator, this applies to B4A, B4J and also B4i.

I've created 5 different examples using B4XPages for new B4X developers...
 

Attachments

  • JSON Generator.zip
    14.9 KB · Views: 504
Last edited:

[B4X] B4X Online Tools - JSON Parser/QR Generator/Regex Parser

button.png button (1).png button (2).png

Full list of B4J Server Examples:

If there are other online tools that simplify programming with B4X...
 

[B4X][B4XPages] SQL + xCLV Example

Attachments

  • SQL + xCLV Example.zip
    347 KB · Views: 930
Top