Java Mail and MS-Exchange Calendar

Hi,

I am trying to access all of the folders of outlook and I have had some luck. I have run into problems with the calendar. I can get all of the information out except for the start and end times of the meeting (rather important pieces of data). I printed out all of the headers and was not able to find this information.

I have seen a lot of simular questions to this on the forum but no real answers. Has anyone done this? Is it possible?

Thanks in advance,

Aaron

[512 byte] By [adwillia] at [2007-9-26 4:07:38]
# 1
hi Aaron,Can please tell how you acces the folders of outlook.Can you please give me some example code.Tomy
tomym at 2007-6-29 13:09:04 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 2

I got most of my code from the tutorial:

http://developer.java.sun.com/developer/onlineTraining/JavaMail/

Here is the code that I used from the above site. I did change the pop3 to imap

import java.io.*;

import java.util.Properties;

import javax.mail.*;

import javax.mail.internet.*;

public class GetMessageExample {

public static void main (String args[]) throws Exception {

String host = args[0];

String username = args[1];

String password = args[2];

// Create empty properties

Properties props = new Properties();

// Get session

Session session = Session.getDefaultInstance(props, null);

// Get the store

Store store = session.getStore("pop3");

// Connect to store

store.connect(host, username, password);

// Get folder

Folder folder = store.getFolder("INBOX");

// Open read-only

folder.open(Folder.READ_ONLY);

BufferedReader reader = new BufferedReader (

new InputStreamReader(System.in));

// Get directory

Message message[] = folder.getMessages();

for (int i=0, n=message.length; i<n; i++) {

// Display from field and subject

System.out.println(i + ": " + message.getFrom()[0]

+ "\t" + message.getSubject());

System.out.println("Do you want to read message? [YES to read/QUIT to end]");

String line = reader.readLine();

if ("YES".equals(line)) {

// Display message content

System.out.println(message.getContent());

} else if ("QUIT".equals(line)) {

break;

}

}

// Close connection

folder.close(false);

store.close();

}

}>

adwillia at 2007-6-29 13:09:04 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 3

Hello.

How are you doing?

Good Day.

I think I have the concepts down some, I'm just gonna

ask some questions for confirmation. First I'll list a

statement then I'll as the question about the

statement.

If the statement is correct answer yes, on the other

hand if the statement is false. Answer no to the

question and explain.

My purpose for asking you questions. Is to get a better understanding of JavaMail and to clear up any doubt. That, I may have on this subject that is related to the statements and questions.

By having some one like you respond to my questions with answers.

Here we go!

The content of the Part Interface and Message class are not attributes at all.

If this statement is correct or not correct please explian why.

Is this statement correct?

A DataHandler is the class called DataHandler and the

object of the DataHandler class, which programmers

would call the DataHandler object; which is (normally

created by using the DataHandler class constructor). The DataHandler class, wraps the data into the DataHandler object which is called DataHandler; by you or I using the DataHandler class constructor.

This statement is correct right?

The DataHandler class takes the data you pass to it's

constructor and wraps it into the DataHandler's object

as one entity called an email message.

Is this statement correct?

Thanks in advance.

Please email me as soon as possible;

at leroy0591@yahoo.com.

Peace out, have a good day.

-Leroy

leroy0591 at 2007-6-29 13:09:04 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...