ClassCastExcpetion Linq to SQL

Posted by BitFiddler on Stack Overflow See other posts from Stack Overflow or by BitFiddler
Published on 2010-03-24T20:50:29Z Indexed on 2010/03/24 20:53 UTC
Read the original article Hit count: 369

I have a column definition in my generated Dbml file:

<Column(Storage:="_Low", DbType:="Decimal(18,2)", UpdateCheck:=UpdateCheck.WhenChanged)>
Public Property Low() As System.Nullable(Of Decimal)

When I try to assign:

With someObject
   .Low = 21.33D
End With

I get a ClassCastException when I call db_context.SubmitChanges(). Anyone have an idea why this is?

Thanks

© Stack Overflow or respective owner

Related posts about LINQ

Related posts about linq-to-sql