My first question: Is the server you are talking to WebDAV enabled
(possibly Apache with mod_dav)?

If it is try to call the WebdavResource constructor with an already
existing URL, for example the parent collection of the resource you
wish to create. Then call wdres.putMethod("/fullPath", file), where
"fullPath" represents the pathname which you want to save your file
as. And forget about WebdavFile, it's currently not maintained.

Regards,
Ingo

> Sorry, Yes I've got an exception in the line where the webdavresource is created 
> (webres =3D new 
> WebdavResource(httpURL);)
> 
> org.apache.commons.httpclient.HttpException: Unable to process request
>         at 
> org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:657)
>         at 
> org.apache.webdav.lib.WebdavResource.propfindMethod(WebdavResource.java:2560)
>         at 
> org.apache.webdav.lib.WebdavResource.propfindMethod(WebdavResource.java:2529)
>         at org.apache.webdav.lib.WebdavResource.setNamedProp(WebdavResource.java:682)
>         at 
> org.apache.webdav.lib.WebdavResource.setBasicProperties(WebdavResource.java:669)
>         at 
> org.apache.webdav.lib.WebdavResource.setProperties(WebdavResource.java:1528)
>         at org.apache.webdav.lib.WebdavResource.setHttpURL(WebdavResource.java:976)
>         at org.apache.webdav.lib.WebdavResource.setHttpURL(WebdavResource.java:995)
>         at org.apache.webdav.lib.WebdavResource.setHttpURL(WebdavResource.java:1074)
>         at org.apache.webdav.lib.WebdavResource.<init>(WebdavResource.java:259)
>         at WebDavTest.main(WebDavTest.java:22)
> 
> 
> Thanx 
> 
> 
> 
> ------- Original message -------=A0
> From:  Martin Dulisch  <[EMAIL PROTECTED]>=A0
> Date: Mon, 3 Nov 2003 09:28:38 +0100=A0
> Subject: Re: Java Client Problem=A0
> 
> What is the exact problem? Do you get a exception?
> 
> Martin
> 
> >> Hi
> >>
> >> I'm new to Slide and WebDav
> >>
> >> I want to use slide for a very simple application.  I want
> >> the application to save a file to the public html directory
> >> from a user on a web server.
> >>
> >> I guess it's very simple but I could no make it works.
> >>
> >> Here's the code I'm using to save the file
> >>
> >> WebdavResource wdres=3Dnull;
> >> String url =3D "http://mywebserver/~user/public_html/dav.xml";;
> >> HttpURL httpURL =3D new HttpURL(url);
> >> httpURL.setUserInfo("user","password");
> >> wdres =3D new WebdavResource(httpURL);
> >>
> >> //boolean done =3D webres.putMethod(file);   //I tried this way
> >> but it didn't work
> >>
> >> WebdavFile webfile =3D new WebdavFile(wdres);
> >>
> >>
> >> Any Ideas will be very much appreciated and a sample code
> >> would be absolutely great
> >>
> >> Thanks
> >>
> >> Capital One Classic
> >> Mastercard
> >> 60 second
> >> response online.
> >> http://mocda.com/1/c/681064/117934/307081/307081
> >>
> >> AOL users go here
> >> http://mocda.com/1/c/681064/117934/307081/307081


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to