Mombu the Microsoft Forum sponsored links

Go Back   Mombu the Microsoft Forum > Microsoft > EXCHANGE SERVER (TECHNET) > Set FolderContent class for a folder created by the HTTPWebRequest
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
11 5th August 20:50
parv
External User
 
Posts: 1
Default Set FolderContent class for a folder created by the HTTPWebRequest



Sorry my mistake, SQL Shd be like this

<?xml version="1.0"?>
<D:searchrequest xmlns = "DAV:" >
<D:sql>SELECT "folderId","DAVarentname" FROM scope('hierarchical
traversal of "http://Jain/public/London"') where "DAV:displayname" =
'folderName'
</D:sql>
</D:searchrequest>

i.e. single quotes rather than double

Best Regards
Parveen Beniwal
  Reply With Quote


  sponsored links


12 5th August 21:40
parv
External User
 
Posts: 1
Default Set FolderContent class for a folder created by the HTTPWebRequest



Hi henning
i am trying to find the folder using this code

string strFolderURI = "http://jain/public";
try
{
Connection exchConnection = new Connection("jain",
ConnectionProtocol.Http,
new Credential("administrator", "hrhk",
AuthenticationType.Ntlm));
Searcher searcher = new
Searcher(strFolderURI,exchConnection);
searcher.PropertiesToLoad.Add("folderId");
searcher.SearchScope = SearchScope.Hierarchical;
searcher.Constraints = "\"DAV:diaplayname\" = 'Test'";
IList<Item> items = searcher.Find();
Console.WriteLine("found: " + items.Count);
}catch(Exception ex){
Console.WriteLine(ex.Message);
Console.WriteLine(ex.StackTrace);
}

But this is giving me the following exception.

Async operation failed. See inner exception for details.
at InfiniTec.Threading.AsyncOperation.EvaluateOperati onResult() in
D:\My Do***ents\Visual Studio
2005\Projects\InfiniTec.Threading\InfiniTec.Thread ing\AsyncOperation.cs:line
214
at InfiniTec.Threading.AsyncOperation.WaitForCompleti on() in D:\My
Do***ents\Visual Studio
2005\Projects\InfiniTec.Threading\InfiniTec.Thread ing\AsyncOperation.cs:line
203
at InfiniTec.Exchange.Searcher.Find() in D:\My Do***ents\Visual
Studio
2005\Projects\InfiniTec.Exchange\InfiniTec.Exchang e\Searcher.cs:line
119
at MyEventSink.ExchangeConnect.SearchItems.Main(Strin g[] srgs) in
D:\Parv\Data\Visual
Basic\MyEventSink\ExchangeConnect\SearchItem.cs:li ne 45

I am not able to understand what i am doing wrong here.... Also same
exception is coming while using the exampleApplication available on
your site.

Best Regards
Parveen Beniwal
  Reply With Quote
13 5th August 21:40
henning krause mvp - exchange
External User
 
Posts: 1
Default Set FolderContent class for a folder created by the HTTPWebRequest


Hello,

please post the stacktrace of the
AsyncOperaitonFailedExecption.InnerException.

Best regards,
Henning Krause
  Reply With Quote


  sponsored links


Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666