Dadaista Active Member Licensed User Longtime User Jul 29, 2016 #1 Hi!! I get this error: B4A version: 6.00 Parsing code. (0.04s) Compiling code. (0.10s) Compiling layouts code. (0.03s) Organizing libraries. (0.00s) Generating R file. (0.64s) Compiling debugger engine code. (1.79s) Compiling generated Java code. Error B4A line: 264 If v Is CustomListView Then javac 1.8.0_66 src\b4a\example\main.java:490: error: incompatible types: View cannot be converted to customlistview if (_v.getObjectOrNull() instanceof b4a.example.customlistview) { The code... Code: Copy Dim panel As Panel panel = Activity.GetView(2) For Each v As View In panel.GetAllViewsRecursive Log(v.Tag) If v Is CustomListView Then 'I suppose is here 'code else if v Is EditText Then 'code End If Next How can I solved it?? thanks in advance edit: this also fails.. Code: Copy Dim panel As Panel Dim k As CustomListView panel = Activity.GetView(2) k = panel.GetView(4)' index of customlistview Last edited: Jul 29, 2016
Hi!! I get this error: B4A version: 6.00 Parsing code. (0.04s) Compiling code. (0.10s) Compiling layouts code. (0.03s) Organizing libraries. (0.00s) Generating R file. (0.64s) Compiling debugger engine code. (1.79s) Compiling generated Java code. Error B4A line: 264 If v Is CustomListView Then javac 1.8.0_66 src\b4a\example\main.java:490: error: incompatible types: View cannot be converted to customlistview if (_v.getObjectOrNull() instanceof b4a.example.customlistview) { The code... Code: Copy Dim panel As Panel panel = Activity.GetView(2) For Each v As View In panel.GetAllViewsRecursive Log(v.Tag) If v Is CustomListView Then 'I suppose is here 'code else if v Is EditText Then 'code End If Next How can I solved it?? thanks in advance edit: this also fails.. Code: Copy Dim panel As Panel Dim k As CustomListView panel = Activity.GetView(2) k = panel.GetView(4)' index of customlistview
RauchG Active Member Licensed User Longtime User Jul 29, 2016 #2 Hi Dadaista, lock here https://www.b4x.com/android/forum/threads/multi-select-spinner-auf-customlistview.68786/#post-436579 Upvote 0
Hi Dadaista, lock here https://www.b4x.com/android/forum/threads/multi-select-spinner-auf-customlistview.68786/#post-436579
Dadaista Active Member Licensed User Longtime User Jul 29, 2016 #3 Hi RauchG, thx for response. I can't see the solution... I don't want get the items of the customlistview. I only want to get the property tag of the customlistview because I saved there some data. With ".GetAllViewsRecursive" is not possible. The compilation fails Never mind...... I will saved the data in another tag property of anycontrol in the panel created. Upvote 0
Hi RauchG, thx for response. I can't see the solution... I don't want get the items of the customlistview. I only want to get the property tag of the customlistview because I saved there some data. With ".GetAllViewsRecursive" is not possible. The compilation fails Never mind...... I will saved the data in another tag property of anycontrol in the panel created.
Erel B4X founder Staff member Licensed User Longtime User Jul 31, 2016 #4 CustomListView type is not a View. The actual view is ScrollView (sv variable). You can make sv a public variable and set its tag. Upvote 0
CustomListView type is not a View. The actual view is ScrollView (sv variable). You can make sv a public variable and set its tag.
RauchG Active Member Licensed User Longtime User Jul 31, 2016 #5 Hi Erel, can you please write a small example. Upvote 0
Dadaista Active Member Licensed User Longtime User Jul 31, 2016 #6 thx Erel but I don't know how to do what you said or my english is awful... or both I don't know how to get the customlistview created in run time. my project is stopped until I can solve it edit: now is when I need to use .AddTextItem.... how can I get de customlistview? Last edited: Aug 2, 2016 Upvote 0
thx Erel but I don't know how to do what you said or my english is awful... or both I don't know how to get the customlistview created in run time. my project is stopped until I can solve it edit: now is when I need to use .AddTextItem.... how can I get de customlistview?