views:

240

answers:

1

I looked at this example http://msdn.microsoft.com/en-us/library/bb399420.aspx and clicked on DataContext.CreateDatabase which brought me to this page http://msdn.microsoft.com/en-us/library/system.data.linq.datacontext.createdatabase.aspx

It says to use System.Data.Linq namespace and include the reference System.Data.Linq.

I have done that and recv the error

error CS0246: The type or namespace name 'Column' could not be found (are you missing a using directive or an assembly reference?)

[Table(Name = "DVDTable")]
public class DVD
{
    [Column(IsPrimaryKey = true)] //<-- here
    public string Title;
    [Column]
    public string Rating;
}

How do i fix this error?

+1  A: 

ColumnAttribute is in the System.Data.Linq.Mapping namespace.

Lucas
Thanks :) .
acidzombie24