D
Dieter Schwerdtfeger via DotNetMonster.com
I have this function where i search through my database for items that were made on a specific date. The line "CType(dvClubs.Item(teller).Item(veld).ToShortDateString" gives me the error : option strict on disallows late binding. I have read some posts here about late binding but I just can't figure it out :s This code worked with option strict off, but i just heard that we had to write our program with option strict on :/
I hope you guys can help me
Public Function ZoekOntstaan(ByVal search As Date, ByVal veld As String) As Integer
For teller As Integer = 0 To dvClubs.Count - 1
If CType(dvClubs.Item(teller).Item(veld).ToShortDateString, String) = search Then
Return teller
End If
Next
Return -1
End Function
I hope you guys can help me
Public Function ZoekOntstaan(ByVal search As Date, ByVal veld As String) As Integer
For teller As Integer = 0 To dvClubs.Count - 1
If CType(dvClubs.Item(teller).Item(veld).ToShortDateString, String) = search Then
Return teller
End If
Next
Return -1
End Function