Есть такой код:
Код: Выделить всё
lv.setOnItemClickListener(new OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> adapter, View view,
int position, long id) {
String idp = ((TextView) view.findViewById(R.id.pid)).getText().toString();
Fragment dateSecond = new DateSecond();
Bundle mBundle = new Bundle();
mBundle.putString(TAG_ID, idp);
dateSecond.setArguments(mBundle);
final FragmentManager fragmentManager = getActivity().getSupportFragmentManager();
final FragmentTransaction fragmentTransaction = fragmentManager.beginTransaction();
//check if the device is landscape or portrait
Configuration configuration = getActivity().getResources().getConfiguration();
int ori = configuration.orientation;
fragmentTransaction.replace(R.id.list, dateSecond);
if(ori == configuration.ORIENTATION_PORTRAIT){
fragmentTransaction.addToBackStack(null);
}
fragmentTransaction.commit();
}
});
E/AndroidRuntime(922): java.lang.IllegalArgumentException: No view found for id 0x7f05003e () for fragment DateSecond{4604dec8 #2 id=0x7f05003e}
Stackoverflow уже весь перерыл =/