Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Look up keyword or section
Like this
2Activity

Table Of Contents

1 Getting started
1.1 Installing Basic4Android and Android SDK
1.1.1 Install and configure Basic4Android
1.2 Installing Android Emulator
2 My first program (MyFirstProgram.b4a)
3 Second program (SecondProgram.b4a)
Sub btnEvent_Click
4 The IDE
4.1 Menu and Toolbar
4.1.1 Toolbar
4.1.2 File menu
4.1.3 Edit menu
4.1.4 Project menu
4.1.5 Tools menu
4.2 Code area
4.2.1 Undo – Redo
4.2.2 Collapse a subroutine
4.2.3 Collapse a Region
4.2.4 Collapse the whole code
The whole code collapsed
4.2.5 Commenting and uncommenting code
4.2.6 Bookmarks
4.2.7 Indentation
4.2.8 Autocomplete
4.2.9 Built in documentation
4.2.10 Jump to a subroutine
4.2.11 Highlighting occurrences of words
4.2.12 Debugging
4.2.13 Breakpoints
4.3 Tabs
4.3.1 Module and subroutine lists
4.3.2 Files
4.3.3 Logs
4.3.4 Libs
5 Screen sizes and resolutions
5.1 Special functions like 50%x, 50dip
5.1.1 PerXToCurrent, PerYToCurrent - 50%x
5.1.2 DipToCurrent - 50dip
5.2 Working with different screen sizes / number of layouts
5.3 Screen orientations
5.4 Supporting multiple sceens - tips and best practices
6 The Emulator
6.1 Launch an Emulator
6.2 Create a new Emulator
6.3 Emulator problems
6.3.1 Process timeout
6.4 Exchanging files with the PC
7 B4A Bridge
8 The Designer
8.1 The menu
8.1.1 File menu
8.1.2 AddView menu
8.1.3 The Tools menu
8.2 Tools
8.2.1 Generate Members
8.2.2 BringTo Front
8.2.3 Send To Back
8.2.4 Duplicate Selected View
8.2.5 Remove Selected View
8.2.6 Change grid
8.2.7 Connect device or emulator
8.3 General settings
8.4 Image files
8.5 Properties list
8.6 Layout variants
8.7 The Abstract Designer
8.7.1 The menu
8.7.2 Context menus
8.7.3 Select views
8.7.4 Example
8.8 Adding views by code
8.9 Designer Scripts
9 Process and Activity life cycle
9.1 How do we handle it ?
9.2 Process global variables
9.3 Activity variables
9.4 Sub Activity_Create (FirstTime As Boolean)
9.5 Globals versus FirstTime
9.6 Sub Activity_Resume Sub Activity_Pause (UserClosed As Boolean)
9.7 Activity.Finish / ExitApplication
10 Variables and objects
10.1 Variable Types
10.2 Names of variables
10.3 Declaring variables
10.3.1 Simple variables
10.3.2 Array variables
10.3.3 Array of views (objects)
10.3.4 Type variables
10.4 Casting
10.5.1 Process variables
10.5.2 Activity variables
10.5.3 Local variables
11 Modules
11.1 Activity modules
11.2 Class modules
11.3 Code modules
11.4 Service modules
12 Tools
12.1 Search function in the forum
12.2 The B4A Documentation Wiki
12.3 B4AHelp
13 Example programs
13.1 User interfaces
13.1.1 Menu example (UserInterfaceMenu.b4a)
13.1.2 TabHost example (UserInterfaceTabHost.b4a)
13.1.3 Button toolbox example (UserInterfaceButtonToolbox.b4a)
13.2 Program with 3 Activities (ThreeActivityExample.b4a)
13.3 ScrollView examples
13.3.1 ScrollView example program
14 Basic language
14.1 Program flow
14.1.1 Process_Globals routine
14.1.2 Globals routine
14.1.3 Activity_Create (FirstTime As Boolean) routine
14.1.4 Activity_Resume routine
14.1.5 Activity_Pause (UserClosed As Boolean) routine
14.3.2 Select – Case
14.4 Loop structures
14.4.1 For – Next
14.4.2 Do - Loop
14.5 Subs
14.5.1 Declaring
14.5.2 Calling a Sub
14.5.3 Calling a Sub from another module
14.5.4 Naming
14.5.5 Parameters
14.5.6 Returned value
14.7.3 Error message "Are you missing a library reference?"
14.8 String manipulation
14.10.1 File object
14.10.2 Filenames
14.10.3 Subfolders
14.10.4 TextWriter
14.10.5 TextReader
14.10.6 Text encoding
14.11 Lists
14.12 Maps
15 Graphics / Drawing
15.1 Overview
15.2 Drawing test programs
15.2.1 Drawing rotating bitmaps / RotatingNeedle
15.2.2 Simple draw functions
16 VB6 versus B4A
17 FAQ
17.1 "Please save project first" message
17.2 "Are you missing a library reference" message
17.3 How loading / updating a library
17.4 When do we need to 'Initialize' and when not
17.5 Split a long line into two or more lines
17.6 Avoid closing an application / capture keycodes like Back / Menu
17.7 Unwanted events like Click, Touch or others
17.8 Adding a Menu item
17.9 How do I remove a View with the Designer
17.10 "Process has timeout" message
17.11 Getting a picture from the gallery
17.12 How to delete x.bal files or other files from a project
17.13 Block a screen orientation
17.14 Close second Activity
17.15 Taking a screenshot programaticaly
17.16 After compiling, where are the files
17.17 Run an application from another one
17.18 How to pass an Array to a Sub
17.19 Getting language and country from device
17.20 Where is the apk file
17.21 Why is my apk filename result.apk
17.22 Why is my apk filename xxx_DEBUG.apk
17.23 Select True / Case trick
17.24 Fill an array with random numbers without repetition
17.25 Detect screen orientation
17.26 Some functions don't work in Activity_Pause
17.27 Calling the internal Calculator
17.28 Get the Alpha / Red / Green / Blue
17.29 Get device type
17.30 Generate a Click event
17.31 "Out of memory" Error / Bitmaps
17.32 Remove the scrollbar from a ScrollView
17.33 Check if directory exists
17.34 Set Full Screen in code
17.35 Change EditText input modes
17.36 Sorting a file list according to last modified time
17.37 Get the dpi values of the device (dots per inch)
17.38 Finding java program lines
17.39 ADB Server not running or not ACK
18 Glossary
0 of .
Results for:
No results containing your search query
P. 1
Beginners Guide

Beginners Guide

Ratings: (0)|Views: 172 |Likes:
Published by ana

More info:

Published by: ana on Jan 16, 2013
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as PDF, TXT or read online from Scribd
See more
See less

03/29/2013

pdf

text

original

You're Reading a Free Preview
Pages 6 to 16 are not shown in this preview.
You're Reading a Free Preview
Pages 22 to 186 are not shown in this preview.
You're Reading a Free Preview
Pages 192 to 195 are not shown in this preview.
You're Reading a Free Preview
Pages 201 to 218 are not shown in this preview.
You're Reading a Free Preview
Pages 224 to 253 are not shown in this preview.

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->