.net - type error in EF 4.1 -


I have created a unit and it has a type int int when I run the project and use this unit I get the following error:

The 'id' property on 'product' can not be set to 'int64' value. You need to set this property in non-null value of type 'Int32'.

How can I fix this?

Edit:

I am using SQL Server and Entity Framework 4.1. I get an error in the administrator's action:

  public functioning test (long id) {return view (repository. Getobliger (id)); }    

You have mentioned that you enter int but If you are going through the long id, try converting it to int or change the id long in the unit.

Comments

Popular posts from this blog

qt - switch/case statement in C++ with a QString type -

python - sqlite3.OperationalError: near "REFERENCES": syntax error - foreign key creating -

Python's equivalent for Ruby's define_method? -