本文整理汇总了C#中DAO.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# DAO.ToString方法的具体用法?C# DAO.ToString怎么用?C# DAO.ToString使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DAO
的用法示例。
在下文中一共展示了DAO.ToString方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SetCounselTeacherForm
public SetCounselTeacherForm(DAO.CounselTeacherRecord.CounselTeacherType Type,List<string> StudentIDList)
{
InitializeComponent();
_UDTTransfer = new DAO.UDTTransfer ();
this.MaximumSize = this.MinimumSize = this.Size;
_CounselTeacherType = Type;
_StudentIDList = new List<int>();
_hasCounselStudent_List = new List<DAO.UDT_CounselStudent_ListDef>();
_StudentIDList = (from data in StudentIDList select int.Parse(data)).ToList();
if(StudentIDList.Count>0)
_hasCounselStudent_List = _UDTTransfer.GetCounselStudentListIDs(StudentIDList);
this.Text = "指定" + Type.ToString();
}
示例2: GetCounselTeacherByType
/// <summary>
/// 透過輔導系統老師類別取得老師
/// </summary>
/// <param name="type"></param>
/// <returns></returns>
public static List<DAO.CounselTeacherRecord> GetCounselTeacherByType(DAO.CounselTeacherRecord.CounselTeacherType type)
{
List<DAO.CounselTeacherRecord> CounselTeacherList = new List<DAO.CounselTeacherRecord>();
QueryHelper hepler = new QueryHelper();
string strSQL = "select distinct teacher.id as id1,tag_teacher.id as id2,teacher.teacher_name,teacher.nickname,tag.name,tag.prefix from teacher inner join tag_teacher on teacher.id=tag_teacher.ref_teacher_id inner join tag on tag_teacher.ref_tag_id=tag.id where tag.prefix='輔導' and tag.name='"+type.ToString ()+"';";
DataTable dt = hepler.Select(strSQL);
foreach (DataRow dr in dt.Rows)
{
DAO.CounselTeacherRecord counselTeacherRec = new DAO.CounselTeacherRecord ();
// 教師編號
counselTeacherRec.TeacherID = dr[0].ToString();
// TeacherTagID
counselTeacherRec.TeacherTag_ID=int.Parse(dr[1].ToString ());
// 教師名稱
if (string.IsNullOrEmpty(dr[3].ToString()))
counselTeacherRec.TeacherFullName = dr[2].ToString();
else
counselTeacherRec.TeacherFullName = dr[2].ToString() + "(" + dr[3].ToString() + ")";
// 類別
counselTeacherRec.counselTeacherType = type;
CounselTeacherList.Add(counselTeacherRec);
}
return CounselTeacherList.OrderBy(x=>x.TeacherFullName).ToList ();
}