triggering email from custom module
You need to implement hook_mail() in your custom module and then call drupal_mail() in your page callback function to get the result you want. You should save your table html in the $params array that gets delivered to hook_mail() and then set it as the $message['body'] value there (with additional html/data if needed). The linked tutorial and API pages should give you enough information and examples to work out the rest of the details.