Android Tutorial B4XTable - Photos Album

Status
Not open for further replies.

Erel

Administrator
Staff member
Licensed User


In this example the table is used to show the camera roll photos.

Main steps:
1. Get permission to access the external storage.
2. Collect the image files from several folders.
3. Add the columns and add ImageViews to all cells.
4. Load the images when the table is updated.
5. Show a dialog with a large image when an image is clicked.
 

Attachments

sz4t4n

Member
Licensed User
I have error with missing .jar
B4X:
B4A Version: 8.80
Parsing code.    (0.13s)
Building folders structure.    (0.09s)
Compiling code.    (0.57s)
Compiling layouts code.    (0.01s)
Organizing libraries.    (0.00s)
Generating R file.    (0.43s)
Compiling generated Java code.    Error
Cannot find: D:\Basic4android\libraries\b4xformatter.jar

But b4xformatter is a .b4xlib. Did I missed something?

upload_2019-3-3_15-14-2.png
 

Erel

Administrator
Staff member
Licensed User
Make sure that there is no file named B4XFormatter.xml in the libraries folders. You should only have a b4xlib file.
 

GMan

Well-Known Member
Licensed User
In the Table-Example is not the Photoalbum example, but another Table-Example
B4X:
    'create the columns
    B4XTable1.AddColumn("US County", B4XTable1.COLUMN_TYPE_NUMBERS)
    B4XTable1.AddColumn("Name", B4XTable1.COLUMN_TYPE_TEXT)
    Dim StateColumn As B4XTableColumn = B4XTable1.AddColumn("State", B4XTable1.COLUMN_TYPE_TEXT)
    StateColumn.Width = 80dip
    NumberColumn = B4XTable1.AddColumn("Interesting Number", B4XTable1.COLUMN_TYPE_NUMBERS)
    CreateCustomFormat(NumberColumn)
    
    'load the data
    Dim su As StringUtils
    Dim headers As List
    headers.Initialize 'the list is only used to skip the headers row
    Dim data As List = su.LoadCSV2(File.DirAssets, "us_counties.csv", ",", headers)
    B4XTable1.SetData(data)
 

Erel

Administrator
Staff member
Licensed User
The photo album example is attached to the first post.
 

GMan

Well-Known Member
Licensed User
I downloaded it again and now its the rigth one

OK, i downloaded the other Example before, too - the same name :D
 

Erel

Administrator
Staff member
Licensed User
You are not posting in the correct place. Search for B4XTable. If you don't find it then start a new thread.
 
Status
Not open for further replies.
Top