Drupal 7 - FAPI - Multistep form - with add another option I'm creating a multistep form in Drupal 7 - FAPI.

In the main hook_form() the redirection to the different steps are handeled.

function hook_form($form, &amp;$form_state) { 
    if (empty($form_state['storage']['step'])) {
        $form_state['storage']['step'] = 0;
    }  

    switch($form_state['storage']['step']) {
        case 0:
          $form=  _step_0($form, $form_state);
        break;
        case 1:
          $form =  _step_1($form, $form_state);
        break;
        case 2:
          $form =  _step_2($form, $form_state);
        break;
        case 3:
          $form =  _step_3($form, $form_state);
        break;
        case 99:
          $form =  _step_end($form, $form_state);
        break;
    }
    return $form;
}

function _step_2($form, &amp;$form_state) {
    ....
    $form['Name'] = array(
        '#title' =&gt; t('Name'),
        '#type' =&gt; 'textfield',
        '#required' =&gt; TRUE,
        '#maxlength' =&gt; 80,
        '#size' =&gt; 80,
    );

        $form['Street'] = array(
        '#title' =&gt; t('Street'),
        '#type' =&gt; 'textfield',
        '#required' =&gt; TRUE,
        '#maxlength' =&gt; 80,
        '#size' =&gt; 80,
    );

    ......

      $form['submit'] = array(
            '#type' =&gt; 'submit',
            '#value' =&gt; 'Next',
      );

    $form['add'] = array(
            '#type' =&gt; 'submit',
            '#value' =&gt; 'Collega toevoegen',
        );
}


In step 2 I have an optional button 'Add onther' which saves the form_values into storage and reloads the same form (step 2). But when it reloads this form for the seconds time. the previous form values are being represented as default form values and not a blank (new) form, which is wanted.

function inschrijven_form_submit($form, &amp;$form_state) {
    switch ($form_state['storage']['step']) {

        case 0:
          switch($form_state['values']['op']) {
            case 'Next' :
              ....
              $form_state['storage']['step'] = 1;
            break;
          }
        break;

        case 1:
          switch($form_state['values']['op']) {
            case 'Next' :
              ....
              $form_state['storage']['step'] = 2;
            break;
          }
        break;

        case 2:
            switch($form_state['values']['op']) {
                case 'Next' :
                    ....
                    $form_state['storage']['step'] = 3;
                break;

                case 'Add another' :
                    $form_state['rebuild'] = TRUE;
                    ....
                    $form_state['storage']['step'] = 2;
                    return;
                break;

        .....

    }
}


I've try to clear the form_state['values'] manually after each submit but with no success. Who can this multistep with add another functionality be achieved?
When you want to add a new set of values, you have to build the form in a different way - the fields that should be "multiplicated" have to be in an array.

so, your 

$form['Name'] = array(
        '#title' =&gt; t('Name'),
        '#type' =&gt; 'textfield',


should instead look like this :

$form['step2'][$i]['Name'] = array( ...


where $i is set to zero in the begining and increased by the callback for your "add another" button. The "step2" fieldset is there just to help you distinguish the parts that are repeated from the others - its not necessary i guess. 
The aformentioned examples module has nice examples how to acheive that even with ajax, so you dont have to reload the whole thing. Dont forget to set 

$form['#tree'] = TRUE;


so that you can process the several sets of results.