android - onCreateDialog() not taking two cases -


i want display timepicker 2 times. retriving start time n stop time. code showing error "duplicate case". tried alot unable find answer silly question. please guide me.

        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;  } 

i think defined 2 constants have same value. need different values.


Comments

Popular posts from this blog

php - cannot display multiple markers in google maps v3 from traceroute result -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -