Today I was working on a demo that someone else started. And then, wouldn't you know, I hit a snag. I decided that now was
the time to learn to use sendmail so I could send my version of code right from my MATLAB session. It was so easy, I thought I'd show you how to do it.
I first tried using sendmail without reading all of the doc, just the input argument list. And I got an error telling me I had to use setpref to set MATLAB up to know about my internet presence. The first error message showed that I had to set up information about
my email account.
I tried sending the message again, and got prompted with a second error, so decided to read the reference page so I would
bypass any other errors as well. Turned out, that wasn't necessary. I fixed my preferences again to set up information about
the mail server.
Now I was in business and able to send the MATLAB code to my co-worker without leaving MATLAB.