If using Rules Scheduler, included in the Rules project, it is possible to schedule execution of rule sets to given dates.

You can for example add a rule that triggers when new user accounts are created, but sends an e-mail to the user in question 2 and 10 days afterwards. The basic flow is as follows:

1. Create a rule set that sends an e-mail to a user. Give the rule set an argument to take in user information (from whatever source). It could say "It has been two days since you registered on our site, and we hope you enjoy it."
2. Create another set as the one above, but with a different message. "It is now ten days since you registered on our site. We miss you!"
3. Make sure you have Rules Scheduler activated.
4. Create a triggered rule, activated on New user account created. Have the triggered rule not do anything in itself, but to schedule a rule set. In the time for evaluation you can type '+2 days' to have the rule set executed on a date relative to whatever time the rule was triggered on. Make sure to send along the registered user as argument to the rule set -- you also have the acting user as an option. (If a user account is created by an administrator, you don't want the e-mail to go to the administrator.)

That's it! Sit back, relax, and let Rules Scheduler do the job for you.

If you want to extend the rule, you can add a rule triggering on user login that removes e-mail number two from the list of queued rules to run. If so, you'll need the ID for the schedule task -- make sure you use sensible IDs (such as 'Send e-mail one to user [user:uid]').

Attached is a [Feature](http://drupal.org/project/features) that installs a triggered rule and two rule sets similar to those described above. You can download and install it as a module, but it is easier if you install the Features module and manage the attached feature as, well, a feature.

As an alternative to the feature, you can just import the rule below

array (
  'rules' => 
  array (
    'send_two_emails_1' => 
    array (
      '#type' => 'rule',
      '#set' => 'rules_send_first_email',
      '#label' => 'Send mail',
      '#active' => 1,
      '#weight' => '0',
      '#categories' => 
      array (
        0 => 'emailing',
        'send_two_emails' => 'send_two_emails',
      ),
      '#status' => 'default',
      '#conditions' => 
      array (
      ),
      '#actions' => 
      array (
        0 => 
        array (
          '#type' => 'action',
          '#settings' => 
          array (
            'from' => '',
            'subject' => '',
            'message' => 'Hello!',
            '#argument map' => 
            array (
              'user' => 'user',
            ),
          ),
          '#name' => 'rules_action_mail_to_user',
          '#info' => 
          array (
            'label' => 'Send a mail to a user',
            'arguments' => 
            array (
              'user' => 
              array (
                'type' => 'user',
                'label' => 'Recipient',
              ),
            ),
            'module' => 'System',
            'eval input' => 
            array (
              0 => 'subject',
              1 => 'message',
              2 => 'from',
            ),
          ),
          '#weight' => 0,
        ),
      ),
      '#version' => 6003,
    ),
    'send_two_emails_2' => 
    array (
      '#type' => 'rule',
      '#set' => 'rules_send_second_email',
      '#label' => 'Send mail',
      '#active' => 1,
      '#weight' => '0',
      '#categories' => 
      array (
        0 => 'emailing',
        'send_two_emails' => 'send_two_emails',
      ),
      '#status' => 'default',
      '#conditions' => 
      array (
      ),
      '#actions' => 
      array (
        0 => 
        array (
          '#type' => 'action',
          '#settings' => 
          array (
            'from' => '',
            'subject' => '',
            'message' => 'Hello again!',
            '#argument map' => 
            array (
              'user' => 'user',
            ),
          ),
          '#name' => 'rules_action_mail_to_user',
          '#info' => 
          array (
            'label' => 'Send a mail to a user',
            'arguments' => 
            array (
              'user' => 
              array (
                'type' => 'user',
                'label' => 'Recipient',
              ),
            ),
            'module' => 'System',
            'eval input' => 
            array (
              0 => 'subject',
              1 => 'message',
              2 => 'from',
            ),
          ),
          '#weight' => 0,
        ),
      ),
      '#version' => 6003,
    ),
    'send_two_emails_3' => 
    array (
      '#type' => 'rule',
      '#set' => 'event_user_insert',
      '#label' => 'Schedule two e-mails when registering',
      '#active' => 1,
      '#weight' => '0',
      '#categories' => 
      array (
        0 => 'emailing',
        'send_two_emails' => 'send_two_emails',
      ),
      '#status' => 'default',
      '#conditions' => 
      array (
      ),
      '#actions' => 
      array (
        0 => 
        array (
          '#type' => 'action',
          '#settings' => 
          array (
            'task_identifier' => 'E-mail one to user [account:uid]',
            'task_date' => '+2 days',
            '#argument map' => 
            array (
              'user' => 'account',
            ),
            '#eval input' => 
            array (
              'token_rules_input_evaluator' => 
              array (
                'task_identifier' => 
                array (
                  0 => 'account',
                ),
              ),
            ),
          ),
          '#name' => 'rules_action_schedule_set_rules_send_first_email',
          '#info' => 
          array (
            'arguments' => 
            array (
              'task_identifier' => 
              array (
                'type' => 'string',
                'label' => 'Identifier',
                'description' => 'User provided string to identify the task. Existing tasks for this rule set with the same identifier will be replaced.',
              ),
              'task_date' => 
              array (
                'type' => 'date',
                'label' => 'Scheduled evaluation date',
              ),
              'user' => 
              array (
                'label' => 'User',
                'type' => 'user',
              ),
            ),
            'label' => 'Schedule "Send e-mail one"',
            'status' => 'custom',
            'categories' => 
            array (
            ),
            'module' => 'Rule Scheduler',
            'base' => 'rules_scheduler_action',
            'set' => 'rules_send_first_email',
          ),
          '#weight' => 0,
        ),
        1 => 
        array (
          '#weight' => 0,
          '#info' => 
          array (
            'arguments' => 
            array (
              'task_identifier' => 
              array (
                'type' => 'string',
                'label' => 'Identifier',
                'description' => 'User provided string to identify the task. Existing tasks for this rule set with the same identifier will be replaced.',
              ),
              'task_date' => 
              array (
                'type' => 'date',
                'label' => 'Scheduled evaluation date',
              ),
              'user' => 
              array (
                'label' => 'User',
                'type' => 'user',
              ),
            ),
            'label' => 'Schedule "Send e-mail two"',
            'status' => 'custom',
            'categories' => 
            array (
            ),
            'module' => 'Rule Scheduler',
            'base' => 'rules_scheduler_action',
            'set' => 'rules_send_second_email',
          ),
          '#name' => 'rules_action_schedule_set_rules_send_second_email',
          '#settings' => 
          array (
            'task_identifier' => 'E-mail two to user [account:uid]',
            'task_date' => '+10 days',
            '#argument map' => 
            array (
              'user' => 'account',
            ),
            '#eval input' => 
            array (
              'token_rules_input_evaluator' => 
              array (
                'task_identifier' => 
                array (
                  0 => 'account',
                ),
              ),
            ),
          ),
          '#type' => 'action',
        ),
        2 => 
        array (
          '#type' => 'action',
          '#settings' => 
          array (
            'message' => 'Two e-mails have been scheduled for sending. You can see them at <a href="/admin/rules/rule_sets/scheduling">the scheduling page for Rules</a> (if you\'re an administrator).',
            'error' => 0,
          ),
          '#name' => 'rules_action_drupal_message',
          '#info' => 
          array (
            'label' => 'Show a configurable message on the site',
            'module' => 'System',
            'eval input' => 
            array (
              0 => 'message',
            ),
          ),
          '#weight' => 0,
        ),
      ),
      '#version' => 6003,
    ),
    'send_two_emails_4' => 
    array (
      '#type' => 'rule',
      '#set' => 'rules_send_first_email',
      '#label' => 'Send mail',
      '#active' => 1,
      '#weight' => '0',
      '#categories' => 
      array (
        0 => 'emailing',
        'send_two_emails' => 'send_two_emails',
      ),
      '#status' => 'default',
      '#conditions' => 
      array (
      ),
      '#actions' => 
      array (
        0 => 
        array (
          '#type' => 'action',
          '#settings' => 
          array (
            'from' => '',
            'subject' => '',
            'message' => 'Hello!',
            '#argument map' => 
            array (
              'user' => 'user',
            ),
          ),
          '#name' => 'rules_action_mail_to_user',
          '#info' => 
          array (
            'label' => 'Send a mail to a user',
            'arguments' => 
            array (
              'user' => 
              array (
                'type' => 'user',
                'label' => 'Recipient',
              ),
            ),
            'module' => 'System',
            'eval input' => 
            array (
              0 => 'subject',
              1 => 'message',
              2 => 'from',
            ),
          ),
          '#weight' => 0,
        ),
      ),
      '#version' => 6003,
    ),
    'send_two_emails_5' => 
    array (
      '#type' => 'rule',
      '#set' => 'rules_send_second_email',
      '#label' => 'Send mail',
      '#active' => 1,
      '#weight' => '0',
      '#categories' => 
      array (
        0 => 'emailing',
        'send_two_emails' => 'send_two_emails',
      ),
      '#status' => 'default',
      '#conditions' => 
      array (
      ),
      '#actions' => 
      array (
        0 => 
        array (
          '#type' => 'action',
          '#settings' => 
          array (
            'from' => '',
            'subject' => '',
            'message' => 'Hello again!',
            '#argument map' => 
            array (
              'user' => 'user',
            ),
          ),
          '#name' => 'rules_action_mail_to_user',
          '#info' => 
          array (
            'label' => 'Send a mail to a user',
            'arguments' => 
            array (
              'user' => 
              array (
                'type' => 'user',
                'label' => 'Recipient',
              ),
            ),
            'module' => 'System',
            'eval input' => 
            array (
              0 => 'subject',
              1 => 'message',
              2 => 'from',
            ),
          ),
          '#weight' => 0,
        ),
      ),
      '#version' => 6003,
    ),
  ),
  'rule_sets' => 
  array (
    'rules_send_first_email' => 
    array (
      'arguments' => 
      array (
        'user' => 
        array (
          'label' => 'User',
          'type' => 'user',
        ),
      ),
      'label' => 'Send e-mail one',
      'status' => 'default',
      'categories' => 
      array (
        0 => 'emailing',
        'send_two_emails' => 'send_two_emails',
      ),
    ),
    'rules_send_second_email' => 
    array (
      'arguments' => 
      array (
        'user' => 
        array (
          'label' => 'User',
          'type' => 'user',
        ),
      ),
      'label' => 'Send e-mail two',
      'status' => 'default',
      'categories' => 
      array (
        0 => 'emailing',
        'send_two_emails' => 'send_two_emails',
      ),
    ),
  ),
)
AttachmentSize
send_two_emails.tgz1.49 KB