B4A Library Grid/Table and ListView Library

This library allows to create easely grids/tables and
from version 2.50
list views too!
Enjoy!
:)

The original post has been moved
http://www.b4x.com/android/forum/threads/grid-library.16381/page-10#post-168452"

Version 2.50 beta
- Added support for multiline rows

Version 2.51 beta
- Bug fixes

Version 2.52 beta
- Added Typeface support for rows and hedaer

Version 2.53
- Added SingleLine property for columns

sample code and usage hints can be found here
http://www.b4x.com/android/forum/threads/grid-library.16381/page-15#post-194602

Version 2.55
- Added object b4aActivityContext

Version 2.56
- Added and modified event hendlers
https://www.b4x.com/android/forum/threads/grid-and-listview-library.16381/page-19#post-297198

Version 2.57
- Added Columns Builders
https://www.b4x.com/android/forum/threads/grid-and-listview-library.16381/page-19#post-299406

Version 2.58
- Bug fixes

Version 2.59
- Added RowHeight for each column
- Added HeaderHeight for each column
https://www.b4x.com/android/forum/threads/grid-and-listview-library.16381/page-19#post-304465

Version 2.60
- Added TouchX() and TouchY()
- Added FirstVisiblePosition() and LastVisiblePosition()
https://www.b4x.com/android/forum/threads/grid-and-listview-library.16381/page-19#post-304905

Version 2.65
- Added Button Columns
https://www.b4x.com/android/forum/threads/grid-and-listview-library.16381/page-19#post-306507

Version 2.67
- Added CellProps event
- Removed PropSetColor / PropSetTextColor
https://www.b4x.com/android/forum/threads/grid-table-and-listview-library.16381/page-19#post-307490

Version 2.71
- Added OnSelectAllow event
- Added selection on row background
https://www.b4x.com/android/forum/threads/grid-table-and-listview-library.16381/page-21#post-347618

Version 2.73
- Added OnRowProps event
https://www.b4x.com/android/forum/threads/grid-table-and-listview-library.16381/page-21#post-349404

Version 2.76
- Fixed dubug log bug
https://www.b4x.com/android/forum/threads/grid-table-and-listview-library.16381/page-21#post-375965

If you like my grid.
You can support the development.


 

Attachments

  • xnGridSample200beta.zip
    3.6 KB · Views: 2,184
  • xnGrid2xx_1.png
    xnGrid2xx_1.png
    77.2 KB · Views: 5,304
  • xnObjects267.zip
    75.7 KB · Views: 925
  • xnObjects272.zip
    87.2 KB · Views: 708
  • xnObjects273.zip
    87.5 KB · Views: 796
  • xnObjects276.zip
    87.2 KB · Views: 1,573
Last edited:

qsrtech

Active Member
Licensed User
Longtime User
Yea I think it would be nice to have each row have an object property to store data. Even one for each column might be usefull.
 

stefanobusetto

Active Member
Licensed User
Longtime User
The grid has been designed mainly to show and select data.
It is also correct you can use hidden columns to store string data.
But a tag field could be useful too.
I'll add the request to the wishlist.
:)
 

stefanobusetto

Active Member
Licensed User
Longtime User
yes
you can open the cursor
loop the records
fill an array or a map with
the data of each record
adding the hidden data
then adding the map or the array
to the grid
:)
 

aviario

Active Member
Licensed User
Longtime User
Hello Stafano, when you can have if you tell me why does not the grid is set GridCreate2 (True)

thanks
 

aviario

Active Member
Licensed User
Longtime User
Hi, When I put two grid in a tabhost shows me the first, but the second if I put cgrid1.GridCreate2 (True) shows nothing

checked it with version 2.5 works ok
 

Attachments

  • TabGrid.zip
    2.5 KB · Views: 249

jrat

Member
Licensed User
Longtime User
After i use gg.RowsDelete() the grid not update view. its freeze at preview state. In Log i sow the select and long select procedures return new values, but screen picture of greed not any changes.

I got it! after RowsDelete() necessary use gg.GridCreate( ) ?
 
Last edited:

stefanobusetto

Active Member
Licensed User
Longtime User
After i use gg.RowsDelete() the grid not update view. its freeze at preview state. In Log i sow the select and long select procedures return new values, but screen picture of greed not any changes.

I got it! after RowsDelete() necessary use gg.GridCreate( ) ?
fixed ( version 2.10 )
thanks for bug reporting
:)
 

aviario

Active Member
Licensed User
Longtime User
IF you take the code from the example really does not work with the DoEvents

thanks
 

Attachments

  • TabGrid.zip
    473 KB · Views: 232

stefanobusetto

Active Member
Licensed User
Longtime User
yes it is but
i don't think double click is a good practice
on android devices
i'll have a look at the google best practices guidelines
:)
 

aviario

Active Member
Licensed User
Longtime User
Hello stefanobusetto, when you can fix the bug GridCreate2 (True)

thanks
 

stefanobusetto

Active Member
Licensed User
Longtime User
posted version 2.22
fixed the bug GridCreate2 (True)
:)

here attached another grid sample app
:)
 

Attachments

  • xnGridSample3.zip
    1.7 KB · Views: 237
  • xnGridSample3.png
    xnGridSample3.png
    64.4 KB · Views: 258

Descartex

Well-Known Member
Licensed User
Longtime User
Hi,
I'm trying to combine this component with SlidingPanels.
I´ve 3 panes with 3 xngrids that shows status tables from different leagues/divisions. I can't found an event in the xngrid that triggers when the user scrolls horizontally in order to change the panel and show the next one.
Is there any solution for this???
Thanks a lot
 
Top