2
Is there a function/module for an object of type List
in VB.NET that is similar to array_map()
of PHP?
The idea is to create a new variable with the elements that satisfy a certain condition.
I have a list of objects of the type FtpListItem
, and only need files where the modification date is greater than the variable UltimoHorario
. Function example:
Function ValidarArquivo(arquivo As FtpListItem)
If arquivo.Modified.Compare(UltimoHorario) > 0 Then
Return True
End If
End Function
Show what you want to do. You can probably use the LINQ
– Maniero
@bigown LINQ can be used with lists? thought it worked only as database mapping..
– Lucio Rubens
@Luciorubens Use LINQ for this. You can even use Lambda Expressions to further simplify the search. For example: Ftplistitem.Where(i => i.Last time >0).
– Joel Rodrigues