[SOGo] accessing and modifying SOGo calenders from c#/java

2011-08-03 Thread rob
Hi,

how do you access  SOGo calendars from c#?
We need it to add calender events to SOGo from a C# program.
My approach was to use IKVM to convert the necessary libraries to dlls for C#.
but:
Using ical4j with ical4j-connector just shows an CalDavStore with an empty
CalDavCollection.

Using ical4j with the /SOGo/dav/user/Calendar/personal.ics file works for
downloading the file, but not for changing/adding events.

What am I doing wrong?

Thanks,
Robin
-- 
users@sogo.nu
https://inverse.ca/sogo/lists


Re: [SOGo] accessing and modifying SOGo calenders from c#/java

2011-08-03 Thread Martin Rabl

Hi,

Am 03.08.2011 15:32, schrieb r...@intego.de:

how do you access  SOGo calendars from c#?

Via CalDAV: /SOGo/dav/user/Calendar/personal


We need it to add calender events to SOGo from a C# program.
My approach was to use IKVM to convert the necessary libraries to dlls for C#.

Not so good. (I tried it last year ;-) )
When you only want to push new events into calendars, its easier to 
wrote a CalDAV-Message direct into SOGo.
CalDAV is a kind of WebDAV, and WebDAV uses http-commands like GET, 
POST, PUT, DELETE.
With PUT, I think, you can create a new entry on the CalDAV-Server 
(aka SOGo).

I.E. this could be done by a command line tool like curl or wget.

Pls have a look at
http://caldav.calconnect.org/

This document http://www.ietf.org/rfc/rfc4791.txt provides some good 
examples, which messages have to sent to the CalDAV-Server.


But if you want to convert Java-Stuff, look here:
http://code.google.com/p/caldav4j/

The OpenConnector-Project has written caldav-client-code in c#,
some code you will find here:
http://otlkcon.svn.sourceforge.net/viewvc/otlkcon/trunk/otlkcon0/OpenConnector/
But, its very buggy, I think.


Using ical4j with the /SOGo/dav/user/Calendar/personal.ics file works for
downloading the file, but not for changing/adding events.
What am I doing wrong?

False URL.

--
Greetings,

   Martin Rabl
--
users@sogo.nu
https://inverse.ca/sogo/lists


Re: [SOGo] accessing and modifying SOGo calenders from c#/java

2011-08-04 Thread Robin Rüde

Hi,
thanks for your answer.

Via CalDAV: /SOGo/dav/user/Calendar/personal
Thats what I tried first, using ical4j-connector. But it just showed an 
empty caldavcollection.



Not so good. (I tried it last year ;-) )
When you only want to push new events into calendars, its easier to
wrote a CalDAV-Message direct into SOGo.

So how did you solve it? ;)
Thats the main use, but seeing overlapping events would be nice.

CalDAV is a kind of WebDAV, and WebDAV uses http-commands like GET,
POST, PUT, DELETE.
With PUT, I think, you can create a new entry on the CalDAV-Server
(aka SOGo).
Yup, I tried it (with ical4j-connector) but it didn't allow to create a 
collection or an object.



Pls have a look at
http://caldav.calconnect.org/

This document http://www.ietf.org/rfc/rfc4791.txt provides some good
examples, which messages have to sent to the CalDAV-Server.

But if you want to convert Java-Stuff, look here:
http://code.google.com/p/caldav4j/

already tried that, but didn't find out how to use it.


The OpenConnector-Project has written caldav-client-code in c#,
some code you will find here:
http://otlkcon.svn.sourceforge.net/viewvc/otlkcon/trunk/otlkcon0/OpenConnector/

But, its very buggy, I think.

I'll look at it



Using ical4j with the /SOGo/dav/user/Calendar/personal.ics file works
for
downloading the file, but not for changing/adding events.
What am I doing wrong?

False URL.
It's the URL shown in SOGo as "WebDAV ICS URL", which was the URL I 
tried after direct CalDAV didn't work.
the WebDAV works for downloading, but not for uploading data. For 
example if you connect from Windows Explorer ("add network resource") to 
http://sogo-demo.inverse.ca/SOGo/dav/sogo1/ with user:sogo pass:sogo,

you can view the calendars but can't upload/change/delete files.

--
users@sogo.nu
https://inverse.ca/sogo/lists


Re: [SOGo] accessing and modifying SOGo calenders from c#/java

2011-08-04 Thread Martin Rabl

Hi,

Am 04.08.11 10:34, schrieb Robin Rüde:

Via CalDAV: /SOGo/dav/user/Calendar/personal

Thats what I tried first, using ical4j-connector. But it just showed an
empty caldavcollection.

Than theres an error in ical4j.


Not so good. (I tried it last year ;-) )
When you only want to push new events into calendars, its easier to
wrote a CalDAV-Message direct into SOGo.

So how did you solve it? ;)

Pffft! It was a long long time ago ... ;-)
Try curl for the network stuff, and read how to wrote an event entry for 
caldav in the RFC - just copy/paste and change the params.


OR: go to the davical-website, the have a php-client for caldav, usable 
as a class.



already tried that, but didn't find out how to use it.

Hmpf. Rtfm?


It's the URL shown in SOGo as "WebDAV ICS URL", which was the URL I
tried after direct CalDAV didn't work.



the WebDAV works for downloading, but not for uploading data. For
Sorry - you didn't understand CalDAV. CalDAV is a special way for 
working with calendar data, based on WebDAV. For putting an event to the 
server, you have to use a special WebDAV(-base) command, which is very 
good documented in the RFC. Just read, copy/past, change the params.


I wrote a little c# caldav-lib some time ago, but its not for production 
use, nor for alpha-use. But it used the examples in the RFC and runs 
quite good with it.


Greetings,
   Martin
--
users@sogo.nu
https://inverse.ca/sogo/lists


Re: [SOGo] accessing and modifying SOGo calenders from c#/java

2011-08-08 Thread Robin Rüde

Hi,
It works now.


Than theres an error in ical4j.

That's possible.

Pffft! It was a long long time ago ... ;-)
Try curl for the network stuff, and read how to wrote an event entry
for caldav in the RFC - just copy/paste and change the params.

Thanks, I already solved it. Using
ical4j for parsing and creating ics files,
apache.commons for sending web requests,
jackrabbit.webdav for Put and PropFindMethods from webdav.
I wrote a little c#-"library" which can get, put and list all VEvents 
from a SOGo server.

So nothing with any special caldav-requests.


already tried that, but didn't find out how to use it.

Hmpf. Rtfm?

couldn't find any manual, sorry ;)

Sorry - you didn't understand CalDAV. CalDAV is a special way for
working with calendar data, based on WebDAV. For putting an event to
the server, you have to use a special WebDAV(-base) command, which is
very good documented in the RFC. Just read, copy/past, change the params.
Yes, thanks for that link, even though I didn't read it fully, it helped 
me understand it.


I wrote a little c# caldav-lib some time ago, but its not for
production use, nor for alpha-use. But it used the examples in the RFC
and runs quite good with it.

Me too, but in a different way

Greetings,
Robin

--
users@sogo.nu
https://inverse.ca/sogo/lists