How do i pop up a list of week days (Monday to Sunday) and user should able to select day(s) as require.
For example, when we set the alarm by clicking Repeat, a list of pops up and user can select days(s). I have attached iOS pictures for the reference.
I am looking for a solution supporting B4i and B4A both.
Dear Erel, thank you very much for the suggestion.
May i further request additional support with some example or link to learn? I have never used B4XDialog + B4XListTemplate.
Sub Class_Globals
Private Root As B4XView
Private xui As XUI
Private dialog As B4XDialog
End Sub
Public Sub Initialize
' B4XPages.GetManager.LogEvents = True
End Sub
Private Sub B4XPage_Created (Root1 As B4XView)
Root = Root1
Root.LoadLayout("MainPage")
dialog.Initialize(Root)
End Sub
Private Sub Button1_Click
Dim listtemplate As B4XListTemplate
listtemplate.Initialize
listtemplate.AllowMultiSelection = True
listtemplate.MultiSelectionMinimum = 1
listtemplate.Options = Array("Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday")
Dim sf As Object = dialog.ShowTemplate(listtemplate, "Ok", "", "Cancel")
Wait For (sf) Complete (Result As Int)
If Result = xui.DialogResponse_Positive Then
Log(listtemplate.SelectedItems)
End If
End Sub
@Erel , i want to index each object of the list so i used following code. In B4i, it works fine but in B4A, it throws error (screenshot attached). What could be the reason?