我想显示 timePicker 2 次。用于检索开始时间 n 用于停止时间。此代码显示错误为“重复大小写”。我尝试了很多,但无法找到这个愚蠢问题的答案。请指导我。
protected Dialog onCreateDialog(int id)
{
switch (id)
{
case TIME_DIALOG_ID1:
// return new TimePickerDialog(this,
// mTimeSetListener, startHour, startMinute, true);
Toast.makeText(getApplicationContext(),"hr:"+startHour+"min:"+startMinute, Toast.LENGTH_LONG).show();
break;
case TIME_DIALOG_ID2:
// return new TimePickerDialog(this,
// mTimeSetListener, startHour, startMinute, true);
Toast.makeText(getApplicationContext(),"hr:"+stopHour+"min:"+startMinute, Toast.LENGTH_LONG).show();
break;
}
return null;
}