Why does WCF return myObject[] instead of List like I was expecting?

前端 未结 4 570
甜味超标
甜味超标 2020-11-27 03:10

I am returning a List from my WCF method. In my client code, it\'s return type shows as MyObject[]. I have to either use MyObject[], or IList, or IEnumerable...



        
4条回答
  •  -上瘾入骨i
    2020-11-27 03:34

    When you add the service reference to the client project click the advanced button and change collection type from array to what you want it to be...

提交回复
热议问题