Hi,
I'm a mess.
I'm using the blow code to open the gallery and grab an image for an
incon im gong to store in a database and access later to populate a
listview attached to a simpleCursorAdapter.
//inside contextmenu
Intent intent = new Intent();
intent.setType("image/*");
intent.setAction(Intent.ACTION_GET_CONTENT);
startActivityForResult(intent, 1);
//activityresult
protected void onActivityResult(int requestCode, int resultCode,Intent
data)
{
if(requestCode == 1){
if(resultCode == RESULT_OK) {
db.open();
db.updateDB(data.getData().toString()); //this updates
the columns in the DB that will later get used for the adapter
db.close();
}
}
}
The code runs, and then starts force closing (what seems like)
randomly. I'm convinced that I've gotten something confused somewhere
but since the force closure happens at all different points of my app
I dont know where to start looking.
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en