Linq Select Certain Properties Into Another Object?

后端 未结 5 681
情书的邮戳
情书的邮戳 2020-12-09 02:24

So say I have a collection of Bloops

Class Bloop
  Public FirstName
  Public LastName
  Public Address
  Public Number
  Public OtherStuff
End Class
<         


        
5条回答
  •  失恋的感觉
    2020-12-09 03:09

    Transforming from one type into another can be accomplished by using Enumerable.Select

    In fact, there is a sample from 101 linq samples that shows a query transforming ints into strings.

提交回复
热议问题