-1
私はprogressdialogを行った後にインテントを追加したい、私はすでにインテントを追加していますが、動作していないので、コンパイル時にエラーが発生します。ProgressDialog内にIntentを追加するには?
ます。private void showProgressDialog(){
progressDialog = new ProgressDialog(this);
progressDialog.setMessage("Validating");
progressDialog.show();
progressDialog.setCancelable(false);
new CountDownTimer(28000, 1000) {
public void onTick(long millisUntilFinished) {
int[] countTimer = new int[] {.......};
String[] setMessage = new String[]{......};
count=count+1;
for(int i=0; i<countTimer.length; i++) {
if (count == countTimer[i]){
progressDialog.setMessage(setMessage[i]);
}
}
}
public void onFinish() {
//the progress is finish
count=0;
progressDialog.dismiss();
Intent i = new Intent(this, Main2Activity.class);
startActivity(i);
}
}.start();
}
私は
Error:(66, 28) error: no suitable constructor found for Intent(<anonymous CountDownTimer>,Class<Main2Activity>)constructor Intent.Intent(String,Uri) is not applicable(argument mismatch;
同様の
YourActivity.this
か気にいらを使用しようと、CountDownTimer
を指し、その仕事 – nicvaldy