Hello sir, I've already done making your suggestion, but my problem is the pnlExpanded, it is not auto resize. I want to resize it depends on the count of the item in customlistview. See attached image:
In Item #3 there are more than 1 SubItem and in Item #4 there is only 1 SubItem. How can i resize the pnlExpanded height to match the number of item in customlistview so i can show all the subitems (so that there's no scroll bar in Item #3) and remove the white (excess space in Item #4) in customlistview?
After finding how to communicate between classes I improved the previous version and since it is completely different, I opened a new thread for it. There is a Tree class, in which you have to define the nature of the tree (what database it displays). This class manages the nodes which are...
B4J v1.05 adds support for the TreeView node. TreeView as it name suggests visualizes a tree structure. Each item in the TreeView is a TreeItem (or CheckBoxTreeItem). Each item has a list of children items. Example: Sub Process_Globals Private fx As JFX Private MainForm As Form...
Download a Library from Here SD_TreeList Author: Star-Dust Version: 0.27 B4XTree Events: Click (IDLeaf As String, LeafName As String) ClickBranch (ID As String, Expanded As Boolean) LongRightClick (IDLeaf As String, LeafName As String) LongRightClickBranch (ID As String, BranchName As...
ExpandableTableView class uses TableView to implement a view that shows a tree of items. Each item can hold other children items. The user can expand or collapse the items. This class uses new methods added in TableView v1.10. These methods (InsertCells and RemoveCells) allow to update the...
pnlExpanded and CustomListView1 should be anchored correctly. This means that they should be vertically anchored to BOTH and fill all the available area:
code:
B4X:
For i = 1 To 20
Dim NumberOfItems As Int = Rnd(1, 20)
Dim p As B4XView = CreateItem(Rnd(0xFF000000, 0xFFFFFFFF), "Item #" & i, NumberOfItems * 52dip + 60dip + 2dip)
clvSidebar.Add(p, expandable.CreateValue(p, "some value"))
For j = 1 To NumberOfItems
CustomListView1.AddTextItem("Subitem #" & j, j)
Next
Next
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.