mardi 4 août 2015

Is there a way to paste a file from the system clipboard to MS Exchange's email as attachment?

I am doing a project that needs to send email from MS Exchange server, but the company has a policy not to turn on smtp/pop3, so I was trying to find another way to send email with Java through Exchange, searched the net couldn't find an answer [ How to send email with java using MS Exchange server? ], then I suddenly realize Java has a robot, why don't I use the robot to simulate a user action to send an email by clicking and typing and attach files as a user would usually do, so with that in mind I was able to use Java robot to open a new email, paste in "To", "CC", "Subject", "Content" and click send, it was successful.

But the only obstacle now is how to simulate the attach file action ? I just learned that Java can copy a file to the system clipboard from this question : Can Java system clipboard copy a file?

The next logical question is : How do you attach this file on the system clipboard on to a new email message in MS Exchange 2013 ? I tried to use shortcuts, but none of the shortcuts has attach function :

http://ift.tt/1gFXTyt

http://ift.tt/1OMftuW

I wonder if I can somehow paste this file on the system clipboard into the email message as attachment ?



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire