Feb 11, 2021 Replies: 2 Hi guys, This is a very simple Custom View Combo box for B4A only. you can modify it to your need. Version : 1 Methods AddSingle(Val As String), add single item to list AddMulti(Val() As String), add multi item to list AddTwoLines(Val1 As String,Val2 As String,RetVal As String), add to line to list GetLv, get List View of the Combo Text, set or get Text of the Combo Event Clicked, fired when you choose an item in the combo box Sample Codes B4X: Copy Sub Globals Private dbYear As CustomDB End Sub Sub Activity_Create(FirstTime As Boolean) For y = 2017 To 2031 dbYear.AddSingle(y) Next End Sub Private Sub dbYear_Clicked Private year as String year = dbYear.Text 'add you own codes' End Sub Attachments Combo.zip Combo.zip 11.3 KB · Views: 1,089 Last edited: Mar 3, 2021 Click to expand...
Hi guys, This is a very simple Custom View Combo box for B4A only. you can modify it to your need. Version : 1 Methods AddSingle(Val As String), add single item to list AddMulti(Val() As String), add multi item to list AddTwoLines(Val1 As String,Val2 As String,RetVal As String), add to line to list GetLv, get List View of the Combo Text, set or get Text of the Combo Event Clicked, fired when you choose an item in the combo box Sample Codes B4X: Copy Sub Globals Private dbYear As CustomDB End Sub Sub Activity_Create(FirstTime As Boolean) For y = 2017 To 2031 dbYear.AddSingle(y) Next End Sub Private Sub dbYear_Clicked Private year as String year = dbYear.Text 'add you own codes' End Sub
incendio Well-Known Member Licensed User Longtime User Mar 3, 2021 #3 There's only click event. Use this code B4X: Copy Sub Globals Private dbYear As CustomDB End Sub Sub dbYear_Clicked 'add your own coding' End Sub
There's only click event. Use this code B4X: Copy Sub Globals Private dbYear As CustomDB End Sub Sub dbYear_Clicked 'add your own coding' End Sub