java - Resources don't contain package for resource number -
i'm trying write simple app widget has config , uses alarmmanager update @ faster pace (it's clock needs current). followed google's examples on how their documentation.
now here's what's going on, clock uses various images display time , when file installed on emulator following error:
resources don't contain package resource number 0x7f0700e5
it says 15 different things varying between drawables, drawables-hdpi , strings. @ first thought this solution might fix issue i'm following google's code @ point.
here's how config file setup:
@override protected void oncreate(bundle savedinstancestate) { log.d(tag, "oncreate"); super.oncreate(savedinstancestate); setresult(result_canceled); setcontentview(r.layout.config); configokbutton = (button)findviewbyid(r.id.btnconfok); configokbutton.setonclicklistener(btnconfokonclicklistener); intent intent = getintent(); bundle extras = intent.getextras(); log.d(tag, "oncreate-if(extras !- null)"); if(extras != null) { mappwidgetid = extras.getint( appwidgetmanager.extra_appwidget_id, appwidgetmanager.invalid_appwidget_id); log.d(tag, "oncreate-mappwidgetid = " + string.valueof(mappwidgetid)); } log.d(tag, "oncreate-if(mappwidgetid == appwidgetmanager.invalid_appwidget_id"); if(mappwidgetid == appwidgetmanager.invalid_appwidget_id){ log.d(tag, "oncreate-invalid appwidget id"); finish(); } } private button.onclicklistener btnconfokonclicklistener = new button.onclicklistener() { public void onclick(view v) { log.d(tag, "onclick"); final context context = wordtimewidgetconfig.this; appwidgetmanager appwidgetmanager = appwidgetmanager.getinstance(context); wordtimewidget.updatewordtimewidget(context, appwidgetmanager, mappwidgetid); // puts clock on schedule keep updated current time log.d(tag, "onclick-creating alarmmanager"); intent intent = new intent(wordtimebroadcastreceiver.wordtime_update_intent); pendingintent pendingintent = pendingintent.getbroadcast(wordtimewidgetconfig.this, result_ok, intent, 0); alarmmanager alarmmanager = (alarmmanager)getsystemservice(alarm_service); calendar calendar = calendar.getinstance(); calendar.settimeinmillis(system.currenttimemillis()); calendar.add(calendar.second, 10); alarmmanager.setrepeating(alarmmanager.rtc, calendar.gettimeinmillis(), wordtimewidget.clock_update_rate, pendingintent); log.d(tag, "onclick-saving alarmmanager"); wordtimewidget.savealarmmanager(alarmmanager, pendingintent); log.d(tag, "onclick-creating intent , finishing method"); intent resultvalue = new intent(); resultvalue.putextra(appwidgetmanager.extra_appwidget_id, mappwidgetid); setresult(result_ok, resultvalue); finish(); } };
this seems pretty straightforward. real weird thing might going on i'm passing widget config context in updatewordtimewidget(context, appwidgetmanager, mappwidgetid);
call.
so doing wrong? appreciated. can supply more code if need be.
Comments
Post a Comment