Knoppi Active Member Licensed User Longtime User Feb 28, 2016 #1 it is possible to use in a CustomView-Library LoadLayout? (transated with google) [German] ist es möglich in einer CustomView-Library LoadLayout zu benutzen? Code: Copy Public Sub AddToParent( Parent As Panel, Left As Int, Top As Int, Width As Int, Height As Int) mCallBackBase = Parent mCallBackBase.AddView( classBase, Left, Top, Width, Height) classBase.LoadLayout("numberpad") I get the following error (ich bekomme folgende Fehler) java.io.FileNotFoundException: numberpad.bal at android.content.res.AssetManager.openAsset(Native Method) at android.content.res.AssetManager.open(AssetManager.java:315) at android.content.res.AssetManager.open(AssetManager.java:289) at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:202) at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:78) at anywheresoftware.b4a.objects.PanelWrapper.LoadLayout(PanelWrapper.java:112) at ths.numberpad.numberpad._addtoparent(numberpad.java:54) ...
it is possible to use in a CustomView-Library LoadLayout? (transated with google) [German] ist es möglich in einer CustomView-Library LoadLayout zu benutzen? Code: Copy Public Sub AddToParent( Parent As Panel, Left As Int, Top As Int, Width As Int, Height As Int) mCallBackBase = Parent mCallBackBase.AddView( classBase, Left, Top, Width, Height) classBase.LoadLayout("numberpad") I get the following error (ich bekomme folgende Fehler) java.io.FileNotFoundException: numberpad.bal at android.content.res.AssetManager.openAsset(Native Method) at android.content.res.AssetManager.open(AssetManager.java:315) at android.content.res.AssetManager.open(AssetManager.java:289) at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:202) at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:78) at anywheresoftware.b4a.objects.PanelWrapper.LoadLayout(PanelWrapper.java:112) at ths.numberpad.numberpad._addtoparent(numberpad.java:54) ...
Erel B4X founder Staff member Licensed User Longtime User Feb 28, 2016 #2 You need to add the file to the Files tab and you need to use CallSubDelayed to load the layout. See this example: https://www.b4x.com/android/forum/t...a-simple-web-style-date-picker.27548/#content Upvote 0
You need to add the file to the Files tab and you need to use CallSubDelayed to load the layout. See this example: https://www.b4x.com/android/forum/t...a-simple-web-style-date-picker.27548/#content