I am trying to set a hyperlink in my eclipse java project.
when someone clicks on a button, it should open up an email client along with the given
email id. is it possible to implement it with java.awt.Desktop?
解决方案
Yes it is possible using desktop.mail()
Desktop desktop = Desktop.getDesktop();
String message = "mailto:dummy@domain.com?subject=First%20Email";
URI uri = URI.create(message);
desktop.mail(uri);
and regarding the mailto URI you have to create it yourself.
A mailto: URI can specify message fields including "to", "cc",
"subject", "body", etc. See The mailto URL scheme (RFC 2368) for the
mailto: URI specification details.