我有一个上课的人,有身份证,姓名和工资属性。
class person
friend id as long
friend name as string
friend salary as decimal
end class
我不想列出工资清单。
Dim pList as new list(of person)
pList加载了50个条目
Dim SalaryList as new list(of decimal)
for each p as person in plist
SalaryList.add(p.salary)
next
好的,这很有效。 但有没有办法像这样做:
Dim SalaryList as list(of decimal) = pList(each).salary