Share

webdavclient4j

The forum address has changed, you have been automatically redirected. Please update any bookmarks to use the new URL.

Subscribe

Some example Code

You are viewing a single message from this topic. View all messages.

  1. 2009-02-06 01:02:33 UTC
    Hello!
    I am not sure this is the place to ask, but I'll try.
    Can someone provide a sample code to get .eml files from Inbox folder of MS Exchange server. Only OWA via https is enabled.

    My code is like one above:

    HttpURL url = new HttpsURL("https://mail.somecompany.com");
    url.setUserinfo("testuser", "userpassword");
    url.setPath("/exchange/mailboxname@somecompany.com/Inbox/");
    WebdavResource wdr = new WebdavResource(url);

    String[] list = wdr.list();
    for (int m = 0; m < list.length; m++)
    {
    System.out.println(list[m]); // that works - prints .eml files
    File localDestination = new File(list[m]);
    tt.getMethod(localDestination);
    }

    This code downloads files as html. In fact even worse - root folder of OWA inbox, so if I must "?Cmd=open" at the end of url to get specific .eml-file (but again formated as html).
    My paths are ok, if I add a new network place in Windows it is possible to view and get eml files. But how to do this in java?

    10x in advance, any help will be useful.
< Previous | 1 | Next >

Add a Reply

This forum does not allow anonymous participation.

Log in to add a reply. Not registered? Create an account to participate and receive email updates when replies are posted to this topic.