My problem does not solved yet but when i use NTCredentials
instead of UsernamePasswordCredentials the server error is
changed from 401 to 409
where at microsoft site say that
Error code 401 Unauthorized(The resource requires
authorization or authorization was refused. [HTTP])
Error code 409 Conflict (A collection cannot be created
until intermediate collections have been created. [WebDAV])
If anyone can help me i will be very thankfull.
My code is:
NTCredentials creds = new NTCredentials(username,
password,serverIP,domainName );
String
path="http://"+serverIP+"/"+exchange
Folder+"/"+calendarUser+"/"+calendar
Folder+"/";
Protocol p = new Protocol( "http", new
DefaultProtocolSocketFactory(), 8090 );
NotificationListener nl = new
NotificationListener("localhost",8090,serverIP,8
0,
p, creds,path,30000,true);
boolean bl= nl.subscribe(
"Update",path,DepthSupport.DEPTH_1,
3600,1,new EventListener(),creds );
System.out.println(bl);
the output is:
false
SEVERE: Subscription for uri='http://10.
10.1.1/exchange/dkamal/calendar/' failed. State: 409
---------------------------------
Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone
calls. Great rates starting at 1¢/min.
---------------------------------
Blab-away for as little as 1¢/min. Make PC-to-Phone Calls
using Yahoo! Messenger with Voice. |