What function should I use in instead of mimemail()? I was using mimemail(), a function defined from the MIME mail module, in Drupal 6 to send emails using attachments.
The Drupal 7 module doesn't have mimemail().
What function should I use in Drupal 7, instead of mimemail()?
The reason the mimemail() function does not exist for Drupal 7 is because it is not needed.

See, for instance, issue: API function for quick send html mail without uneccessary operations (mimemail analog from 6.x) in the project's issue queue;


  On Drupal 7 calling drupal_mail() is enough. See the README.txt and drupal_mail_system() for more information.


The general idea is that you set up the Drupal to use MimeMailSystem for some or all mail messages sent by your module:

mailsystem_set(array(
  '{$module}_{$key}' =&gt; 'MimeMailSystem', // Just messages with $key sent by $module.
  '{$module}' =&gt; 'MimeMailSystem', // All messages sent by $module.
));


and then calling drupal_mail() is enough.