Exception raised during rendering: ScrollView can host only one direct child
ScrollView只能有一个子元素,所有用Layout包裹一下android.content.res.Resources$NotFoundException: String resource ID #0x1
因为方法的重载,可能导致接收的参数类型不同,导致调用重载方法,例如 textview.setText(int id) 和 String text 这就是来两个方法,从而导致的异常。
@android.view.RemotableViewMethod
public final void setText(int resid) {
setText(getContext().getResources().getText(resid));
}
@android.view.RemotableViewMethod
public final void setText(CharSequence text) {
setText(text, mBufferType);
}