You cannot directly change an item's From field using any programming methods in Microsoft Exchange or Outlook. If you could, mail could be sent on someone else's behalf without their permission, therefore the From field is read-only.
You can use the SentOnBehalfOfName property to set the From field, provided that you were given delegate permissions to send mail on someone else's behalf.
Executed the above code. but i got some errors.
Those are Microsoft office outlook warning
" A program is trying to automatically send e-mail on your behalf.
Do you want to allow this?
if this is unexpected, it may be a virus and you should choose "No" ."
i used to click yes
i am getting error " Outlook does not recognize one or more names. "
This is error is shown at .send
Actually, sasureshh, Mark has a very good point. Besides that you only see the 'From' field when you RECEIVE a mail and never when sending as this is a template format that is altered once it reaches the exchange server and then passed out to the relevant mail account space for the end user to pick up in the mail client.