首页 / 浏览问题 / 移动GIS / 问题详情
com.supermap.realspace.SceneControl
12EXP 2020年05月14日
super.onCreate(savedInstanceState);
requestPermissions() ;
Environment.setLicensePath(sdcard+"/SuperMap/license/");
Environment.initialization(this);

info = new WorkspaceConnectionInfo();
// 组件功能必须在 Environment 初始化之后才能调用
setContentView(R.layout.activity_main);   //这里报错
mSceneControl = (SceneControl) findViewById(R.id.scenecontrol);
// 获取当前许可的状态,返回true 许可可用,返回false 许可不可用,不可用情况下无法打开本地场景。
isLicenseAvailable = isLicenseAvailable();
// 获取场景控件,在许可可用情况下打开本地场景。

<com.supermap.realspace.SceneControl
    android:id = "@+id/scenecontrol"
    android:layout_width="match_parent"
    android:layout_height="match_parent" />

Caused by: android.view.InflateException: Binary XML file line #6: Binary XML file line #6: Error inflating class com.supermap.realspace.SceneControl
Caused by: android.view.InflateException: Binary XML file line #6: Error inflating class com.supermap.realspace.SceneControl
Caused by: java.lang.reflect.InvocationTargetException

1个回答

您好,报错原因是因为布局文件报错,您看一下您是否引用libimb_v1001.so和realspace的jar包
9,127EXP 2020年05月14日

加了的两个都有

...