Lambda with No Args : Lambda « LINQ « VB.Net






Lambda with No Args

   

Option Strict On

Public Delegate Function GetTime() As String

Module Test
  Sub Main()
    Dim t As New GetTime(Function() DateTime.Now.ToString())
    Console.WriteLine(t)
  End Sub
End Module

   
    
    
  








Related examples in the same category

1.Lambda expression syntax
2.Lambdas with Multiple Params
3.LINQ query with Enumerable / Lambdas
4.Use Lambda Function to wrap a query