Re: Close OWA Connection
- From: NgelW <NgelW@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 19 Apr 2006 08:01:01 -0700
Thanks - I have tried to implement this as a GET call (hacked from a function
performing a POST call), but it returns a "Cannot send a content-body with
this verb-type" error <see code snippet below>
Is there (yet again) something obvious that I am doing wrong? Also, it
suprises me a little that I don't need to use the cookies gained when I
established my connection to OWA to terminate the connection?!?
----- code snippet -----
public void BreakAuthentication(string uri)
{
//Paramters
HttpWebRequest request;
HttpWebResponse response;
byte[] body;
Stream stream;
string uriToUse;
//Update URI
uriToUse = uri.Substring(0, uri.IndexOf("/", 8)) + "/?Cmd=logoff";
//Build request
request = GetRequestObject(uriToUse, "GET");
//This is probably the problem?!? What sort of Content-Type should I
//use?
request.ContentType = "application/x-www-form-urlencoded";
//Send request to server
stream = request.GetRequestStream();
stream.Close();
//Get response
response = (HttpWebResponse)request.GetResponse();
}
---- end code snippet ----
"Glen Scales [MVP]" wrote:
Are you using Exchange 2003 is so you could just make a call to the OWA.
Logoff command eg
GET /exchange/user/?Cmd=logoff
cheers
Glen
"NgelW" <NgelW@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:77572BDF-93BC-4C03-B904-264774EEE3DE@xxxxxxxxxxxxxxxx
Hi,
In a c# app, I have established a connection to OWA, and done what I need
to
do on the exchange server, and would now like to close that connection
rather
then allowing it to time-out. Can anyone explain how this can be done?
Many thanks,
Nigel
- Follow-Ups:
- Re: Close OWA Connection
- From: Glen Scales [MVP]
- Re: Close OWA Connection
- References:
- Re: Close OWA Connection
- From: Glen Scales [MVP]
- Re: Close OWA Connection
- Prev by Date: Re: Where do you find the item URL?
- Next by Date: MSG File Format
- Previous by thread: Re: Close OWA Connection
- Next by thread: Re: Close OWA Connection
- Index(es):
Relevant Pages
|