Java Applets (4)
Exchange Links About this site Links to us 
|
Send an Email from a Java applet
2 comments. Current rating: (1 votes). Leave comments and/ or rate it.
Question: How do I send an email from my java applet?
Answer: Here's an easy shortcut using the mailto: protocol handler. You can add arguments to the url using the subject and body field.
For full control, research the Java mailAPI.
 | |  | | try {
URL mail = new URL("mailto: billgates@macrosoft.com?subject=my subject&body=my message text");
}
catch (MalformedURLException e) {
System.err.println("Invalid URL");
}
getAppletContext().showDocument(mail);
| |  | |  |
Comments:
|
irowatt@intercoast.com.au from Australia
|
 |
|
|
hello 1154
|
|
anonymous from United States
|
|
|
|
|
|