0

我是使用 WCF for silverlight 的新手,有人可以帮帮我吗?这让我发疯!

我在 service1.cs 中的代码是:

[OperationContract]
    public List<PublishedSoftwareItem> GetSoftwareByArea(int ID)
    {
        ProductionFileManager manager = new ProductionFileManager();
        using (LinqToSQLPublishedSoftwareDataContext con = new LinqToSQLPublishedSoftwareDataContext())
        {
            var listOfSoftware = new List<PublishedSoftwareItem>();
            var getSoftware = from a in con.PublishedSoftwares
                              join b in con.Areas on a.AreaID equals b.AreaID
                              join c in con.ImageDataStores on a.ImageStoreID equals c.ID
                              select new PublishedSoftwareItem
                              {
                                  Description = a.SoftwareDescription,
                                  PublishLink = a.PublishLink,
                                  Title = a.SoftwareName,
                                  SoftwareImage = manager.GetImageFromDatabase(ID)

                              };
            listOfSoftware = getSoftware.ToList();

            return listOfSoftware;
        }

    }

当我更新我的reference.cs 时,我的reference.cs 变得一团糟,服务不再正常工作。我已取消选中重用类型复选框,但这没有帮助。请有人帮忙。询问您是否需要更多信息

4

1 回答 1

0

你应该重新审视这个链接:

WCF 服务参考使用

于 2013-05-18T11:05:49.563 回答