B4J Question [ABMaterial]: Multi-Select Dropdown Wanted.

Harris

Expert
Licensed User
Longtime User
AddArrayComponent.... when you thought something was direct and simple, often this solves the issue.

You need to AddItem that includes checkbox ( a suggestion)
agend.AddItem(""&id, fn, BuildSimpleItem("11", "mdi-action-star-rate", fn)) ' that is a checkbox (or something that has a State prop).

Where BuildSimpleItem adds an ArrayComponent (or you add it upon return).

Then, you could check which items were selected.

I do this now on a similar issue (page component) . I do not know if a ABMCombo would/could support this (would be nice). I have a similar issue - but wish to restrict a ABMList within a cell - then scroll for more).

https://www.b4x.com/android/forum/threads/abmaterial-create-toast-with-no-timeout.80429/#post-509838

We are only limited by our (perceived) needs - and the existing framework...

EDIT: I have found that trying to access a STATE prop, issues a FutureChecked and never returns the (checked) state of the component. Only AddArrayComponent resloves this and shows the current state.
 
Last edited:
Upvote 0

alwaysbusy

Expert
Licensed User
Longtime User
AddArrayComponent...
This would indeed be the way to go, as it has to support touch devices too. Haven't tried it on a combo yet however.

EDIT: I have found that trying to access a STATE prop, issues a FutureChecked and never returns the (checked) state of the component.
Can you elaborate a bit on this? (or give me some sample code to reproduce this). It could be a bug.
 
Upvote 0

Harris

Expert
Licensed User
Longtime User
This would indeed be the way to go, as it has to support touch devices too. Haven't tried it on a combo yet however.


Can you elaborate a bit on this? (or give me some sample code to reproduce this). It could be a bug.
In my post above is a link to the PutNewMail() sample.
Instead of a new ABMCard, use ABMCheckbox. Instead of AddArrayComponent, use AddComponent to the same cell of a container. When root is a page, it works - has issue with containers.
 
Upvote 0
Top