I have a IMAP server host name : xyz.com. And my SMTP host name is : comcast.net.
Now when I send emails via Outlook it automatically shows my ID [sender ID] as : myusername@xyz.com and not myusername@comcast.net.
I would like to achieve the same using JavaMail API.
When I use JavaMail API, it shows the sender as myusername@comcast.net. I understand this is the way it works. IMAP for receiving emails and SMTP for sending emails.
However, I would like to develop the behavior similar to that of Outlook where it sets IMAPs server hostname, instead of the SMTP's server hostname, in the sender ID.
Thanks & Regards, Ravikiran Mane.