我在ButterKnife中遇到此错误:
错误:找不到符号方法findById(View,int)
TextView tvHeaderTextOne = ButterKnife.findById(headerView, R.id.tv_header_text_one);
更新到Butterknife 10之后,出现错误,无法显示findById
。
定义道具
@BindView( R.id.tv_header_text_one)
protected TextView tx ;
在OnCreate方法中:
ButterKnife.bind(this,yourview);