I've tried to use this library to retrieve messages with a windows service in my internal Microsoft Exchange Server.
I can access the server and read messages with thunderbird so IMAP service is working correctly.
When I try to retrieve messages with S22 I always get an exception on GetMessages
The exception is
System.ArgumentException Message: Value cannot be null - parameter name: value
in StackTrace I found this method
in System.Net.Mime.HeaderCollection.Add(String name, String value)
if I hit F10 in Visual studio during debug the the Message of the Exception change
Value cannot be null - Parameter name Key
an in the StackTrace now there is
in System.Collections.Generic.Dictionary`2.FindEntry(TKey key)
The code ise very simple and copied from your examples:
IEnumerable<uint> uids = client.Search(SearchCondition.All()); var messages = client.GetMessages(uids,true);
after hitting many times the F10 button the procedure go forward and is able to read messages and attachment. It looks there are messages the missing something and cause the exception when the Method create the MailMessage object.
I've tried to use this library to retrieve messages with a windows service in my internal Microsoft Exchange Server. I can access the server and read messages with thunderbird so IMAP service is working correctly. When I try to retrieve messages with S22 I always get an exception on GetMessages The exception is
System.ArgumentException Message: Value cannot be null - parameter name: value
in StackTrace I found this method
in System.Net.Mime.HeaderCollection.Add(String name, String value)
if I hit F10 in Visual studio during debug the the Message of the Exception change
Value cannot be null - Parameter name Key an in the StackTrace now there is
in System.Collections.Generic.Dictionary`2.FindEntry(TKey key)
The code ise very simple and copied from your examples:
IEnumerable<uint> uids = client.Search(SearchCondition.All()); var messages = client.GetMessages(uids,true);
after hitting many times the F10 button the procedure go forward and is able to read messages and attachment. It looks there are messages the missing something and cause the exception when the Method create the MailMessage object.
Edika