【发布时间】:2018-12-12 16:37:27
【问题描述】:
我会关注以下链接,但对我没有帮助:
每当我添加以下代码时:
// get our folding cell
final FoldingCell fc = (FoldingCell) findViewById(R.id.folding_cell);
// attach click listener to folding cell
fc.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
fc.toggle(false);
}
});
这个错误来了:Illegal character U+200B
错误未显示在Logcat 或massage 上,它显示在MainActivity.class 下方findviewById 中
activity_main.xml
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.foldingcell.MainActivity">
<com.ramotion.foldingcell.FoldingCell
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/folding_cell"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:clipChildren="false"
android:clipToPadding="false"
>
</com.ramotion.foldingcell.FoldingCell>
</LinearLayout>
【问题讨论】:
-
你能分享你的整个 logcat 错误/布局和活动代码
-
in
Logcat无法显示任何错误 -
我会关注下面的链接,但对我没有帮助 - 我复制了你的代码,得到了同样的错误,删除了空白行,然后它就起作用了。我无法想象它对你不起作用。告诉我为什么我不应该以重复的形式结束这个问题,为什么它对你不起作用?
-
我已经试过了,这真的不适合我@TimCastelijns
-
你做了什么?你是剪断线然后把它贴回去还是什么的?如果您只是删除该行,则错误仍然存在是不可能的
标签: java android illegal-characters