none
Linq to SQL via WCF Services RRS feed

  • Question

  • I have successfully set up services for my silverlight application using Linq to SQL I just don't know how to correctly configure the service.  I need to be able to display query results in the data grid.  Trying to access the stored procedure.

    this is the IService code.

    
    
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Runtime.Serialization;
    using System.ServiceModel;
    using System.Text;
    
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the interface name "IService" in both code and config file together.
    [ServiceContract]
    public interface IService
    {
      [OperationContract]
      List<Contract> GetContract(string Contract);
    }
    
    I don't know how to structure the Services.cs file- I keep getting errors.
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Runtime.Serialization;
    using System.ServiceModel;
    using System.Text;
    
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the class name "Service" in code, svc and config file together.
    public class Service : IService
    {
    	public void DoWork()
    	{
    	}
    }
    Wednesday, July 14, 2010 8:23 PM

Answers

All replies