Tutorials & Examples

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

Auto starting your app

Hi all!

Here is what you need to auto start your app at boot up.
Create a service module and paste in the code below:


B4X:
#Region  Service Attributes
    #StartAtBoot: True
#End Region

Sub...
 
Last edited:

Simple switch button with image view

Hi
The application I'm writing I need switches, but not being an expert I arranged with some simple line of code. The result is good and does its work.
I used an image view and an int variable...
 

Attachments

  • SwitchButton.zip
    110.8 KB · Views: 1,241
  • screen.png
    screen.png
    32.9 KB · Views: 1,823
  • 2015-04-07 23_30_37-slide.png
    2015-04-07 23_30_37-slide.png
    163.5 KB · Views: 1,682
Last edited:

Create online UI flow

Hi
I found a site that create ui(contain many views) and relate with together
I cannot explain complete please visit it
fluidui.com
 

Using standard Android search dialog with Basic4Android

Search is a core feature of Android. You can use a configurable standard search dialog for performing searches in your app. This search dialog can also be used within a Basic4Android App (with...
 

Attachments

  • SearchExample.zip
    8.1 KB · Views: 2,099
  • screenshot-1330509212682.jpg
    screenshot-1330509212682.jpg
    12.5 KB · Views: 2,440
Last edited:

Add border to Views and change Checkbox graphic

Here are a couple of routines that may come in handy.

The first adds a background to a view which can have a fill color, rounded corners and a border color. This is useful for picking out views...
 

Attachments

  • screenshot.png
    screenshot.png
    25 KB · Views: 3,666
  • AddBorder.zip
    8.8 KB · Views: 1,810
Last edited:

Very simple push service with a txt file

With this service, you can make some push notification with a .txt file.
 

Attachments

  • verysimplepush.zip
    10.1 KB · Views: 665

Simple ComboBox concept: WORKS!

hey guys... since we cant enter text but only select in spinner...
i have a small simple concept that can make it like our old VB combo box

its got to do with... aligning an edittext and a...
 

Attachments

  • MyComboBox.zip
    7 KB · Views: 1,151

Debugging android applications

Tutorial covering the new "Rapid Debugger" deployment mode is available here:
Rapid Debugger


This tutorial explains the debugging features added in Basic4android v1.50 as well as the...
 
Last edited:

Create your layouts based on percentages

Attachments

  • lm PercLayout.zip
    16.6 KB · Views: 687
Last edited:

Android based Closed Circuit TV (CCTV) example

Attachments

  • CCTVServer.zip
    30.1 KB · Views: 4,657
  • CameraCCTVClient.zip
    10.3 KB · Views: 4,500
Last edited:

game scailing (ui game objects ... etc)

So Erel pointed out to me about my question about ui and scailing. He said to use percentages. So I did some research. I looked up how to do it in html5 and verious other languages. So I was...
 
Last edited:

BitmapMeshView

You can play around with this. Posting the following:

B4A project (BitmapMeshView.zip)
Java Code (src.zip)

Amend the Java code to your liking.
Click on the blank screen once the project has...
 

Attachments

  • BitmapMeshView.zip
    209.8 KB · Views: 722
  • src.zip
    4.4 KB · Views: 719

Broken LCD Source code

Hi to all,special Erel :)
I have a source code that i gift to forum and all programmer in this forum
It is look like the Broken LCD App in Android app store.

you can see tutorial from below link...
 

Android In-app Billing tutorial

ASMX Soap call,automatic call,response,parse and redirect to activity/service.

Attachments

  • B4A_WSNET_Sample.zip
    71.3 KB · Views: 1,036
  • WSNET_VS2012.zip
    117.3 KB · Views: 835

Alternative way to create Progress Indicators

gifProgressIndicator.png


The attached project is a "short cut" that will enable you to create Progress Indicators for your projects. It makes use of GIF files to simulate the progress indicators. The B4A...
 

Attachments

  • JHS GIF LOADERS.zip
    433.2 KB · Views: 1,153
  • 27.zip
    309.5 KB · Views: 938
Last edited:

Simple Pong Game

Hey guys!!

Here's a simple example of a 2 player Pong game, using nothing more than the core library.
Please keep in mind that this is just the frame-work for what could be a more advanced game...
 

Attachments

  • Pong.zip
    355.4 KB · Views: 1,725
Last edited:

Google ARC Welder

Embedding files in compiled libraries

It is possible to embed files directly in the compiled libraries by following these steps:

1. Add the attached class module, JarFileLoader, to your code (Project - Add Existing Module).
2...
 

Attachments

  • JarFileLoader.bas
    837 bytes · Views: 1,185

Protect your Database against SQL Injection

Hi guys!

This might not the sexiest nor the most elegant piece of code, but it works for me.
Hopefully, someone will find it useful... :)

SQL injection is a code injection technique, used...
 
Last edited:
Top