There are a couple of things going on.
First, you have an FK to some lookup value. You can easily get that using Viv's suggestions.
Second, you need a picklist in a dropdown to select the value from when you create or edit. Putting the SelectList in the ViewModel as I suggested is the best way to go with that.
>The only thing is set in the database, as far as relationship, is Foreign Key Constraint for the field Reference in ReferenceCode table and the same field name (Reference) in the Orders table. And I don't know if this is the "relationship" that is needed for EF or there is something other than that.
>Thank you.
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer