Hello,
When i'm in onActivityResult and i try to show a custom progress dialog,
The dialog is not show, but the function is called, but nothing is displayed
If i put this dialog in Oncreate it's working i see the dialogbox,
Is it possible to show a custom dialog on return of Intent.ACTION_GET_CONTENT / MediaStore.ACTION_IMAGE_CAPTURE
Thanks
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
Parseur UploadPhoto = new Parseur();
showDialog(PROGRESS_DIALOG);
if (requestCode == z_const.REQUEST_INTENT_CODE_PHOTO_CHOISIR) {
String selectedImagePath;
Uri selectedImageUri;
if (data != null){
selectedImageUri = data.getData();
selectedImagePath = getPath(selectedImageUri);
Log.e(TAG, "PHOTO CHOISIR " + selectedImagePath+"Res"+resultCode);
UploadPhoto.uploadPhoto(InfoPasse,selectedImagePath);
}
}
finish();
}
protected Dialog onCreateDialog(int id) {
Log.e(TAG," DIAL appeller "+id);
switch(id) {
case PROGRESS_DIALOG:
progressDialog = new ProgressDialog(Photo.this);
progressDialog.setProgressStyle(ProgressDialog.STYLE_HORIZONTAL);
progressDialog.setMessage("Loading...");
progressThread = new ProgressThread(handler);
progressThread.start();
return progressDialog;
default:
return null;
}
}