Android sub-activity
<p>I have a Main activity with 3 buttons with these buttuns i pass values to my child activity number 2 and in child 2 i do something with these values.</p>

<p>Main class:</p>

<pre><code>    uopgleuf = (Button) findViewById(R.id.fullslot);
   uopgleuf.setOnClickListener(new OnClickListener() {

   @Override
   public void onClick(View v) {
    Intent i = new Intent(UopActivity.this, fullslotActivity.class); // Go to child 2.
    Bundle b = new Bundle();
    b.putString("material", mat.getSelectedItem().toString());
        b.putString("dm", freesdia.getSelectedItem().toString());
        b.putString("endm", endmill.getSelectedItem().toString());
        i.putExtras(b);
        startActivity(i);
    }
   });
</code></pre>

<p>....</p>

<p>Child 2 class:</p>

<pre><code> public final static int SUCCESS_RETURN_CODE = 1;

  Bundle b = getIntent().getExtras(); 
  mater = b.getString("material");
  d = b.getString("dm");
  endmill = b.getString("endm");
</code></pre>

<p>do something with these values.
In the same child 2 class i set on the end these code:</p>

<pre><code> Intent intent = new Intent(fullslotActivity.this, dataActivity.class); // Want to go to child 1 but it return to Main class.               
                Bundle extras = new Bundle(); 
                extras.putString("snedebreedte", "ae");
                intent.putExtras(extras);
                setResult(SUCCESS_RETURN_CODE, intent);
                finish();
</code></pre>

<p>When i push the button in child 2 i would return the values to child number 1 and put the values in TextViews.</p>

<p>child 1 class:</p>

<pre><code>protected static final int SUB_ACTIVITY_REQUEST_CODE = 1;
</code></pre>

<p>And in the same class:</p>

<pre><code>    @Override  
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
     super.onActivityResult(requestCode, resultCode, data);

     if(requestCode ==  SUB_ACTIVITY_REQUEST_CODE){
    Bundle b = data.getExtras();
    snedeb.setText(b.getString("snedebreedte"));
}
</code></pre>

<p>Now my problem is when i finish child 2 the values return automaticaly to the Main activity.</p>

<p>This not what i want is there solution for this.</p>

<p>Were can i place startActivityForResult . I don't want to place it in the Main activity.</p>

<p>Placing the startActivityForResult in child didn't work.</p>

<p>Thanks in advance.</p>
