Tutorials & Examples

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

[B4X] RandomUser API - SMM + lazy loading list + DDD

1760519045466.png


Cross platform example of showing a list of users, retrieved from https://randomuser.me/

The API returns a list with the data of 150 random users. The list is parsed and added...
 

Attachments

  • RandomUser.zip
    187.7 KB · Views: 231

User Login Demo - how-to features

Hi y'all,
I've been working on a demonstration app that would show a bunch of how-to's.

Specifically, how to use an "admin" user and a regular user (non-admin) for login data admin (CRUD).
All...
 

Attachments

  • UserAdminDemo.zip
    30.1 KB · Views: 205
  • 1.jpg
    1.jpg
    179 KB · Views: 424
  • 3.jpg
    3.jpg
    264.9 KB · Views: 420
Last edited:

Share SQLite database between 2 devices

This is just a proof of concept to show that Device A behave like a server hosting a database and Device B connects to it accessing the "shared" database. It is a response to this question...
 

Attachments

  • ShareDB.zip
    17.6 KB · Views: 649
Last edited:

OSMDroid - MapView for B4A tutorial

Attachments

  • 01 - SimpleMap.zip
    5.8 KB · Views: 5,174
Last edited:

Lottie Example with 16kb support

This example is based on the Lotti Library by DonManfred found here. (It still works)

I tried it on 16kb android 15 emulator and...
 

Attachments

  • LottieEx16kb.zip
    13.8 KB · Views: 175
Last edited:

[B4X]How to Implement Lottie in B4XPages (AXrLottie B4A, iLotttie B4i and B4J)

This is B4XPages example for LOTTIE implementation on Android (B4A), iOS (B4I) and Desktop (B4J)

B4A Implementation

Uses AXrLottie. Download the library and dependencies...
 

Attachments

  • LottieB4XExample.zip
    102 KB · Views: 656
Last edited:

[B4X] Class templates

*** This is a trick, a discovery by @aeric, really very useful ***

[B4A-B4J-B4i]


[This is a long post but the process is much simpler than it...
 

Attachments

  • 1758258608074.png
    1758258608074.png
    4.4 KB · Views: 293
Last edited:

[B4X] #CustomBuildAction

The #CustomBuildAction attribute allows running external programs during the compilation process.
The syntax is:
B4X:
#CustomBuildAction <compilation step>, command to run, zero or more arguments...
 
Last edited:

[B4X] Comment Links and #Macros

qHTNrUJnPQ.gif


Comment Links

Code comments can include clickable links. The following schemes are supported:

http(s):// - Link will be...
 
Last edited:

Expandable list based on CustomListView

Last edited:

[B4X] TextEditor - Save and load external files

This is a B4i and B4A example, which demonstrates various external files related tasks.

1626784777442.png
1626784790557.png


The behavior is not exactly the same as the platforms capabilities and behavior...
 

Attachments

  • TextEditor.zip
    184.2 KB · Views: 2,693
Last edited:

[B4X] WebView + CKEditor (rich text editor)

1628407653890.png


This is a cross platform example that adds CKEditor rich text editor using WebView: https://ckeditor.com/ckeditor-5/
Make sure to read CKEditor licensing and pricing...
 
Last edited:

[B4X] B4XCache - simple and useful cache collection

B4XCache is a new collection added in B4XCollections v1.10.
It is key / value store collection, similar to Map.
When the cache reaches the set maximum size, the least recent used items are removed...
 
Last edited:

[B4X] CreateB4XFont

This is an example in response to this post and extension of the example posted here.

B4X:
Private Sub Button1_Click
    #If B4i
    Label1.Font = CreateB4XFont("D3-Biscuitism-Bold"...
 

Attachments

  • CreateB4XFont.zip
    119 KB · Views: 174
Last edited:

[B4X] Localizator B4XPages

A B4X project example to use Localizator in B4XPages
The device locale is selected for B4XCombobox by default.
This is answer to this question...
 

Attachments

  • LocalizatorB4XPages.zip
    20.9 KB · Views: 180

Play Games Services - Example and Class

Last year, I commissioned Biswajit to write a library for the new Google Play Games Services library. To manage the complexity of the code, I wrote a class called...
 

Attachments

  • Play Game Services Example.zip
    29.1 KB · Views: 629

Tips or Tricks for using Android Emulator

I want to share a few tricks when using the Android Virtual Device or Emulator.

1. Increase font and icon size
Go to Settings (gear icons) from drawer/desktop/slide down menu and choose...
 

Attachments

  • 1703145831287.png
    1703145831287.png
    313.3 KB · Views: 2,867
Last edited:

[B4XPages] Admob Example

Check this other excellent example from @Jack Cole.

To help the new members to make money with B4A, I tried to compile all the relevant Admob code (except mediation) of the...
 

Attachments

  • b4xpages_admob_example7.zip
    59.7 KB · Views: 279
Last edited:

MidiSystem Midi Monitor

This example is deprecated, see Midi Monitor2

This is the last example for now, it provides a midi monitor for messages based on the midi channel that the messages are played on.

It...
 
Last edited:

Midi Monitor2

This is a rewrite of the original midi monitor example as a CustomView in a B4xPages project. It eliminates the need for threading and the AcceleratedSurface libraries.

1752691417905.png
...
 

Attachments

  • MidiMonitor2.zip
    12.4 KB · Views: 186
Last edited:
Top