Calling WCF service Asynchronously in Console Application - VS 2008 (Framework - 3.5).

Hi,

WCF Service Library:

[ServiceContract(Name = "IAddService")]
public interface IAddServiceAsync
{
    [OperationContract(AsyncPattern = true)]
    IAsyncResult BeginAdd(int a, int b, AsyncCallback callback, object state);

    int EndAdd(IAsyncResult result);
}

WCF Host (Console App):

  <system.serviceModel>
    <services>
      <service name="AddService">
        <endpoint address="" contract="ServiceLibrary.IAddService" binding="basicHttpBinding"></endpoint>
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior>
          <!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
          <serviceMetadata httpGetEnabled="true"/>
          <!-- To receive exception details in faults for debugging purposes, set the value below to true.  Set to false before deployment to avoid disclosing exception information -->
          <serviceDebug includeExceptionDetailInFaults="true"/>
        </behavior>
      </serviceBehaviors>
    </behaviors>
    <serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
  </system.serviceModel>


WCF Client (Console App):

Please provide the client code for calling the above WCF Service asynchronouly using 1) Delegates 2) Callbacks in VS 2008 (Framework - 3.5).

Thanks
milani_lucieAsked:
Who is Participating?
 
milani_lucieAuthor Commented:
I have gone through those sites.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.