我的問題,當我換三類 第一類是開始的DropDownList在包裝類兩類
[Bind(Exclude="ID")]
public class Material
{
public string MaterialName { get; set; }
}
第二類是
[Bind(Exclude="ID")]
public class ExameState
{
public string ExamState { get; set; }
}
第三類是
[Bind(Exclude="ID")]
public class Exams
{
public string ExamsName { get; set; }
public DateTime CreationDate { get; set; }
public DateTime StartingDate { get; set; }
public int Period { get; set; }
public int ExamStateID { get; set; }
public int MaterialID { get; set; }
public int GroupID { get; set; }
public int QuestionState { get; set; }
public int TeacherID { get; set; }
public int ExamMarkState { get; set; }
public string Password { get; set; }
}
包裝類是
public class Examswrapper
{
public Material material { get; set; }
public ExameState examstate { get; set; }
public Exam exam { get; set; }
}
我需要datavalue = MaterialName 並鑑於關鍵= ID建立在Examswrapper類顯示下拉列表物料 我想這
如何使它 ,感謝您的諮詢
新錯誤: System.NullReferenceException:未將對象引用設置爲對象的實例。
存在類材料沒有身份證,缺少什麼? – 2011-03-13 10:12:22