protected void onActivityResult(int requestCode, int resultCode, Intent data) { if (requestCode == ADD_NEW_USER_REQUEST) { if (resultCode == RESULT_OK) { // User input received Bundle extras = data.getExtras(); PersonModel m_pm = (PersonModel) extras.get("UserInput"); // Store input in central db AppharborWrapper ah = new AppharborWrapper(m_pm); FaceComWrapper fcw = new FaceComWrapper(); try { m_pm = ah.addPerson(m_pm); // Add person to face.com, with the PersonID generated by AH m_pm = fcw.addPerson(m_pm); // Put the tagID from Face.com in AH ah.attachTag(m_pm.getID_DESCRIPTION(), m_pm.getIdTag()); } catch (MalformedURLException e) { e.printStackTrace(); } TextView tv = (TextView) findViewById(R.id.textView1); if (ah.errorCode != "") { tv.setText("ERROR: " + ah.errorCode); } else { tv.setText("Person added succesfully, and will now be available for recognition"); Button button1 = (Button) findViewById(R.id.button1); button1.setText(""); button1.setEnabled(false); Button button2 = (Button) findViewById(R.id.button2); button2.setText(""); button2.setEnabled(false); Button button3 = (Button) findViewById(R.id.button3); button3.setText("OK"); // button3.setOnClickListener(new View.OnClickListener() { // @Override // public void onClick(View arg0) { // // Run face recognition activity // // TODO: Should return to WingmanActivity.class instead // Intent myIntent = new Intent(getBaseContext(), WingmanActivity.class); // startActivity(myIntent); // finish(); // } // }); } } } }