What must be done to get a simple text message mailed to an internet mail address using VC++ (and any class libraries with MS VC++ 4.2)?

I want a function that takes 3 arguments:

int SendEmailMessage(char *emailaddress,char *subject,char *message);