M mw71 Well-Known Member Licensed User Longtime User Jun 19, 2019 #1 Hi, i have a CustomListView 1). Each Panel hold a Table 2). The User can select diffrent Lines on Table. With press on the Button1 (right down corner) i will get the (Data from the) selected Rows (from all Tables on all Panels from CLV). At the moment i get only the Data from the last Table (on the last Panel). Test Project is attached. 1) https://www.b4x.com/android/forum/t...g-or-collapsing-xcustomlistview-items.106148/ 2)https://www.b4x.com/android/forum/threads/class-flexible-table.30649/ Attachments CLV_WithTable.zip CLV_WithTable.zip 47.8 KB · Views: 300
Hi, i have a CustomListView 1). Each Panel hold a Table 2). The User can select diffrent Lines on Table. With press on the Button1 (right down corner) i will get the (Data from the) selected Rows (from all Tables on all Panels from CLV). At the moment i get only the Data from the last Table (on the last Panel). Test Project is attached. 1) https://www.b4x.com/android/forum/t...g-or-collapsing-xcustomlistview-items.106148/ 2)https://www.b4x.com/android/forum/threads/class-flexible-table.30649/
Erel B4X founder Staff member Licensed User Longtime User Jun 19, 2019 #2 1. You are not using CLVExpandable. CLVExpandable is a class that extends xCustomListView library. 2. Table1 will point to the last table added. Change your code to: Code: clv1.Add(CreateItem(Colors.Cyan, "Item #" & i,"citylist_" & i & ".csv"), Table1) Don't use Table1 in your code. Get the correct item with CLV.GetItemFromView. Get the table with: Code: Dim tbl As Table = clv.GetValue(i) Upvote 0
1. You are not using CLVExpandable. CLVExpandable is a class that extends xCustomListView library. 2. Table1 will point to the last table added. Change your code to: Code: clv1.Add(CreateItem(Colors.Cyan, "Item #" & i,"citylist_" & i & ".csv"), Table1) Don't use Table1 in your code. Get the correct item with CLV.GetItemFromView. Get the table with: Code: Dim tbl As Table = clv.GetValue(i)
M mw71 Well-Known Member Licensed User Longtime User Jun 19, 2019 #3 Erel, Thank you i have Change. With Code: For i = 0 To clv1.GetSize - 1 Dim tbl As Table = clv1.GetValue(i) Log("Panel " & i & ", Size: " & tbl.SelectedRows.Size) Next (and set the Value to Table) it works as expected. also i have change to the internal Libary. Upvote 0
Erel, Thank you i have Change. With Code: For i = 0 To clv1.GetSize - 1 Dim tbl As Table = clv1.GetValue(i) Log("Panel " & i & ", Size: " & tbl.SelectedRows.Size) Next (and set the Value to Table) it works as expected. also i have change to the internal Libary.