Are you using your network server for mail or a web server? If your ISP needs credentials, you may not want to script this, since everything sent out is text. On the other hand, if you need to send data to a secure page (better security), you would need to know the form name, the id and password field names in order to script your browser prior to sending the email.
I'm a little suprised since ISP mail servers rarely ask for credentials when sending mail. Tells us more about your mail server. Note: If you're using Outlook, you'd need to script Outlook for this, not the browser.
Let us know.