Tutorials & Examples

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

How to write a sudoku solver

As the sudoku solving contest winner I will now explain the solution I created. I must say that my solution is highly based on a solution I found in a blog post from a canadian student on the...
 

Attachments

  • Sudoku.apk
    90.3 KB · Views: 786
  • Sudoku_lib.zip
    7.5 KB · Views: 868
  • SudokuSolver_Library.zip
    5.8 KB · Views: 881

Style guide for Android interface design

Sliding (Toolbox) panel?

Hi!

I was wondering if creating a panel(toolbox) with, let's say 6 buttons on it, a panel larger than activity.width ("with 2 buttons " :) ) is possible...
User is suppose to...
 
Last edited:

Working with Samsung Galaxy Tab

The Samsung Galaxy Tab is a neat Tablet running Android 2.2.

The following steps are required in order to connect it to the IDE.
- When the device is not connected, go to Settings -...
 

Listview Divider Line Color

How can i define the Color of the horizontal Lines between Listview Items?
 

Nice utity for wireless file transfers

SwiFTP Server
This utility allows you to transfer files or applications to a device that is not connected by cable to your computer.
You can find it by searching the Android market. When it...
 

File Path |Dir|Folder

I have filename.csv file contained two fields?
What folder do I have to copy my filename.csv file so I can access the csv file using loadcsv. eg.
Dim su As StringUtils
Dim Table As List
Table...
 

display and save select item or data to another view and panel tutorial

Hi all,

For those who wants to implement this handling/behaviour to his/her
app, take the example zip underneath.

Special thanks to Klaus, who made a nice solution for this.:sign0098...
 

Attachments

  • TwoActivitiesDisplayResultsViews1.zip
    8 KB · Views: 618

Voice Recognition and activity lifecycle

This might be obvious to some but it caused me some grief so hopefully I can spare someone else some grief.
When using Voice Recognition I have found that it defies the activity lifecycle. What...
 

Imageview related with sdcard getting images examples

Hi,

There are 2 versions to do that:

1. a combination of a button and an imageview.

2. touching the imageview(s) only.

Both ways, after touching the imageview or button, you first have...
 

Attachments

  • imageview_and_buttonclick_to_a_sdcard_example.zip
    5.6 KB · Views: 686
  • imageview_click_to_a_sdcard_example.zip
    5.6 KB · Views: 632

OAuth - How to roll your own (easy).

Hello,

I have seen a few unanswered OAuth questions here and since making an app for an existing site almost always needs OAuth, I decided to check out what was available.

Whilst the...
 

Splash screen

This is the code:
B4X:
'Activity module
Sub Process_Globals
   'These global variables will be declared once when the application starts.
   'These variables can be accessed from all modules...
 

Press button makes a spinner (in)visible examples

Hi,

For those who wants this activity to implement in their own project,
there are two versions of examples available to choose from.
One from Kickaha (many thanks) and one by me.

So...
 

Attachments

  • SpinnerVisibility by Asmoro.zip
    20.5 KB · Views: 808
  • SpinnerVisibility by Kickaha.zip
    20.7 KB · Views: 684

Can you continue a program line across editor lines?

in some langauges you can do something like

B4X:
a=1000 _
  + 50

So _ means "continues on the next line"

Is there something similar in b4a?
 

Help library reference

I'm trying to make a app with "phone events",
ex. get the number of incoming call into a textbox
ex. is phone ringing ?
iex. is phone idle ?
etc, etc

I'm missing some kind of library for...
 

Pong - a game

Hi,

I have attached a little game. It's the old Pong.
At this time I still have no Android device. (Christmas will be soon :sign0060:)

Could someone be so nice to test it on a device and...
 

Attachments

  • pong.zip
    46.6 KB · Views: 909

Access any database or system with B4AServer

Users who are not familiar with B4AServer project should start with this tutorial.

It is sometimes much easier to access data from a desktop than to access the data directly from the...
 

Hello World - Video example

Adding Background or image file top activity

Hello,
I am new to this forum, I have just installed the IDE.
Congratulations on the ease of use! Having messed around with WinDev for a while, which costs a fortune compared to B4A I am...
 

How to get out of a loop

I have several lines of data like this in a file
1,1000,1000,point1
2,1027.699,1030.228,point2
3,1045.671,1070.345,point3
4,2345.123,1098.346,point4
.
.
etc.

When I enter a point number...
 
Top