I try to show A ProgressDialog
while switching one Fragment
to another Fragment
such as message "please wait..." or "loading page..." etc I need to add this message because loading time of Fragment
even I have added getSupportFragmentManager().executePendingTransactions();
after commit my Fragment
transition, I have try as below :
ProgressDialog pd= ProgressDialog.show(getActivity(), "Please Wait","loading page...");
getFragmentManager().beginTransaction().replace(R.id.frame_container, new TertanggungPolis()).
setTransition(FragmentTransaction.TRANSIT_FRAGMENT_OPEN).commit();
pd.dismiss();
But this code seems not working, becase there's no ProgressDialog
that shown in my application, so is there something wrong with my code or my method? thank you