File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Other JSE/JEE APIs and the fly likes PJA Toolkit Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "PJA Toolkit" Watch "PJA Toolkit" New topic

PJA Toolkit

pcss Roy

Joined: Dec 16, 2004
Posts: 2

We are using PJA toolkit to generate a graph & display on a servlet access. OS is AIX. Even though we are able to see the lines of the graph but fonts are not getting displayed on the graph. Can anyone please help me how to sort the problem.

Thanks in advance


Joe Ess

Joined: Oct 29, 2001
Posts: 9189

Welcome to the JavaRanch. I'm going to ask you to change your displayed name to conform to our
naming policy. In short, your name must be a first name and last name, separated by a space and not obviously fake.
As for your question, the PJA toolkit is not part of the Java IO library, so I'm going to move it to the Other Java API's Forum. Follow up in this topic.

[How To Ask Questions On JavaRanch]
Damanjit Kaur
Ranch Hand

Joined: Oct 18, 2004
Posts: 346

I need to write a program for sending email to some Hotmail account. I am using javamail API. I am totally new to javamail API and writing email programs.

Here is a part of my program code ( which I got from one of demo folder of javamail API ):

String from = "";
String url = null;
String mailhost = null;
String mailer = "smtpsend";
String protocol = null, host = null, user = null, password = null;
String record = null;// name of folder in which to record mail
boolean debug = false;
boolean verbose = false;
boolean auth = false;
SMTPTransport t=null;

Properties prop = System.getProperties();
prop.put("", mailhost);
prop.put("mail.smtp.auth", "true");

// Get a Session object
Session session = Session.getInstance(prop, null);

// construct the message
Message msg = new MimeMessage(session);
msg.setFrom(new InternetAddress(from));
msg.setRecipients(Message.RecipientType.TO,InternetAddress.parse(textTo.getText(), false));
msg.setRecipients(Message.RecipientType.CC,InternetAddress.parse(textCc.getText(), false));
msg.setHeader("X-Mailer", mailer);
msg.setSentDate(new Date());
t = (SMTPTransport)session.getTransport("smtp");
t.connect(mailhost, user, password); // because author is true

System.out.println("got connected");

t.sendMessage(msg, msg.getAllRecipients());

System.out.println("message sent");

}catch(MessagingException ms){System.out.println(ms);}
if (verbose) System.out.println("Response: " + t.getLastServerResponse());
try{ t.close(); }catch(MessagingException m){System.out.println(m);}

System.out.println("\nMail was sent successfully.");


In the above code I want to know
- what are ' mailhost and host ' and what value I should put there in case I want to send the email to Hotmail account?
- Somewhere I read hotmail doesn't uses smtp for sending emails. In that case the code I am writing above is wrong. What should I change?
- Also If I should use some smtp server to send emails to hotmail account or I can just send emails without it.

I might be asking some silly questions but please answer me.

Damanjit Kaur
Ranch Hand

Joined: Oct 18, 2004
Posts: 346

O no,I am really sorry I posted the question here by mistake.
Mark Stein
Ranch Hand

Joined: May 20, 2002
Posts: 75
It's been a while since I configured and used PJA, but I do remember I configure a line in my webserver startup script to get it to run. One of the parameters included in that line pointed to my font library. Hope that's helpful.
I agree. Here's the link:
subject: PJA Toolkit
It's not a secret anymore!