i want to use smm in my project.
now i have imageview in all activity and not to change to panel.
i use this code
B4X:
Dim im As ImageView
im.Initialize("im")
Activity.AddView(im,0,0,100%x,100%y)
MediaManager.SetMediaFromFile(im,File.DirAssets,"ims.jpg","image/png", Null)
but this error show.
B4X:
smmviews$ResumableSub_AddMediaresume (java line: 121)
java.lang.RuntimeException: Type does not match (class android.widget.ImageView)
at anywheresoftware.b4a.objects.B4XViewWrapper.typeDoesNotMatch(B4XViewWrapper.java:405)
at anywheresoftware.b4a.objects.B4XViewWrapper.asPanelWrapper(B4XViewWrapper.java:111)
at anywheresoftware.b4a.objects.B4XViewWrapper.AddView(B4XViewWrapper.java:341)
at b4a.example.udp.smmviews$ResumableSub_AddMedia.resume(smmviews.java:121)
The first parameter must be a panel. SMM will add a view based on the content type (and it will reuse views when possible). In the case of images it will add a B4XImageView, which is a cross platform ImageView.