This line of code
((Matches)Container.DataItem).MatchID
works in C# but in VB.NET, when used in a Repeater, I get the error
'Matches' is a type and cannot be used as an expression.
Suggestions?
This line of code
((Matches)Container.DataItem).MatchID
works in C# but in VB.NET, when used in a Repeater, I get the error
'Matches' is a type and cannot be used as an expression.
Suggestions?
That's because it is C# and not VB.NET.
I think the cast syntax for VB.NET looks something like:
CType(Container.DataItem, Matches).EmpID
but no doubt a VB.NET expert will chime in if this is wrong.