Posts

Showing posts from December, 2008

How to add soap header to WCF service call. Part 1

Yeah, I've tried different solutions, spent a lot of hours and nerves. Interesting situation, when became deadline to workaround this problem - the key have been found quickly. The trick is to wrap service call with OperationContextScope and add to current operation context outgoing message a header- and that's it :). using (TestServiceClient testClient = new TestServiceClient()) {     using (OperationContextScope scope = new OperationContextScope(testClient.InnerChannel))     {         MessageHeader header = MessageHeader.CreateHeader("MyTestHeader", "", "Test Value");         OperationContext.Current.OutgoingMessageHeaders.Add(header);         testClient.DoTestCall();     } }

Next task

It seems that I must develop smth. for import contacts from most popular web mail services. Well, interesting task, will see... J

First phrase - first step

So lets blogging... :)