79265875

Date: 2024-12-09 17:21:25
Score: 1.5
Natty:
Report link

I love dylansweb's answer because it discusses the fact that you need to have access to an SMTP server. However, to connect to it you will need a client library. Recently, I too needed to send an email programmatically, albeit in python - not C#. I brought up an SMTP server on my own computer, however, it was unsuccessful transporting an email. I don't know why it didn't work. Perhaps the server wasn't actually on the internet, for which it would need a publicly accessible IP address - not just a home network IP? I decided to go with Google's server, and I got it to work! Please note that to log into my gmail account to send the email, I had to set up an app password.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (1):
Posted by: Sanjay Sridharan