This question is locked. New answers and comments are not allowed.
In my view I have the following coding.
columns.ForeignKey(o => o.BuyerID, (IEnumerable)ViewData["buyers"],
"Id", "Name").Title("Buyer");
Model it is as,
public int BuyerID
{
get;
set;
}
The foreign key works fine in the view. But, when I use the edit and insert mode, It shows the Id instead of name. What is wrong here?
columns.ForeignKey(o => o.BuyerID, (IEnumerable)ViewData["buyers"],
"Id", "Name").Title("Buyer");
Model it is as,
public int BuyerID
{
get;
set;
}
The foreign key works fine in the view. But, when I use the edit and insert mode, It shows the Id instead of name. What is wrong here?