首页 / 浏览问题 / 移动GIS / 问题详情
运行安卓8C开发指南中的程序报错
匿名
2018年05月07日
layout文件和mainactivity和开发指南中的一样

报错如下:

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.century.jiuzhou.envisurvey/com.century.jiuzhou.envisurvey.MainActivity}: android.view.InflateException: Binary XML file line #10: Error inflating class com.supermap.mapping.MapView

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2193)

at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2243)

at android.app.ActivityThread.access$800(ActivityThread.java:135)

at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)

at android.os.Handler.dispatchMessage(Handler.java:102)

at android.os.Looper.loop(Looper.java:136)

at android.app.ActivityThread.main(ActivityThread.java:5019)

at java.lang.reflect.Method.invokeNative(Native Method)

at java.lang.reflect.Method.invoke(Method.java:515)

at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)

at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)

at dalvik.system.NativeStart.main(Native Method)

Caused by: android.view.InflateException: Binary XML file line #10: Error inflating class com.supermap.mapping.MapView

at android.view.LayoutInflater.createView(LayoutInflater.java:620)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696)

at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)

at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)

at android.view.LayoutInflater.inflate(LayoutInflater.java:492)

at android.view.LayoutInflater.inflate(LayoutInflater.java:397)

at android.view.LayoutInflater.inflate(LayoutInflater.java:353)

at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:290)

at android.app.Activity.setContentView(Activity.java:1929)

at com.century.jiuzhou.envisurvey.MainActivity.onCreate(MainActivity.java:43)

at android.app.Activity.performCreate(Activity.java:5231)

at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1104)

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2157)

... 11 more

Caused by: java.lang.reflect.InvocationTargetException

at java.lang.reflect.Constructor.constructNative(Native Method)

at java.lang.reflect.Constructor.newInstance(Constructor.java:423)

at android.view.LayoutInflater.createView(LayoutInflater.java:594)

... 23 more

Caused by: java.lang.UnsatisfiedLinkError: Couldn't load imb from loader dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.century.jiuzhou.envisurvey-1.apk"],nativeLibraryDirectories=[/data/app-lib/com.century.jiuzhou.envisurvey-1, /system/lib]]]: findLibrary returned null

at java.lang.Runtime.loadLibrary(Runtime.java:358)

at java.lang.System.loadLibrary(System.java:526)

at com.supermap.data.Environment.LoadWrapJ(Environment.java:419)

at com.supermap.data.Environment.InternalLoadWrapJ(Environment.java:984)

at com.supermap.mapping.g.a(InternalEnvironment.java:22)

at com.supermap.mapping.MapControl2.<clinit>(MapControl2.java:43)

at com.supermap.mapping.MapControl.a(MapControl.java:55)

at com.supermap.mapping.MapControl.<init>(MapControl.java:29)

at com.supermap.mapping.MapView.a(MapView.java:82)

at com.supermap.mapping.MapView.<init>(MapView.java:73)

... 26 more

android.view.InflateException: Binary XML file line #10: Error inflating class com.supermap.mapping.MapView

at android.view.LayoutInflater.createView(LayoutInflater.java:620)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696)

at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)

at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)

at android.view.LayoutInflater.inflate(LayoutInflater.java:492)

at android.view.LayoutInflater.inflate(LayoutInflater.java:397)

at android.view.LayoutInflater.inflate(LayoutInflater.java:353)

at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:290)

at android.app.Activity.setContentView(Activity.java:1929)

at com.century.jiuzhou.envisurvey.MainActivity.onCreate(MainActivity.java:43)

at android.app.Activity.performCreate(Activity.java:5231)

at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1104)

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2157)

at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2243)

at android.app.ActivityThread.access$800(ActivityThread.java:135)

at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)

at android.os.Handler.dispatchMessage(Handler.java:102)

at android.os.Looper.loop(Looper.java:136)

at android.app.ActivityThread.main(ActivityThread.java:5019)

at java.lang.reflect.Method.invokeNative(Native Method)

at java.lang.reflect.Method.invoke(Method.java:515)

at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)

at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)

at dalvik.system.NativeStart.main(Native Method)

Caused by: java.lang.reflect.InvocationTargetException

at java.lang.reflect.Constructor.constructNative(Native Method)

at java.lang.reflect.Constructor.newInstance(Constructor.java:423)

at android.view.LayoutInflater.createView(LayoutInflater.java:594)

... 23 more

Caused by: java.lang.UnsatisfiedLinkError: Couldn't load imb from loader dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.century.jiuzhou.envisurvey-1.apk"],nativeLibraryDirectories=[/data/app-lib/com.century.jiuzhou.envisurvey-1, /system/lib]]]: findLibrary returned null

1个回答

1)先确定设置的许可有效;

2)先初始化环境,然后再设置布局。
2,042EXP 2018年05月07日
...