本文整理汇总了C#中Grade.GetFriendlyName方法的典型用法代码示例。如果您正苦于以下问题:C# Grade.GetFriendlyName方法的具体用法?C# Grade.GetFriendlyName怎么用?C# Grade.GetFriendlyName使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Grade
的用法示例。
在下文中一共展示了Grade.GetFriendlyName方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SetNewAssessmentTitleValue
protected void SetNewAssessmentTitleValue()
{
_sessionObject = (SessionObject)Page.Session["SessionObject"];
string grade = _sessionObject.AssessmentBuildParms["Grade"];
Grade gradeOrdinal = new Grade(grade);
string subject = _sessionObject.AssessmentBuildParms["Subject"];
int courseID = DataIntegrity.ConvertToInt(_sessionObject.AssessmentBuildParms["Course"]);
Base.Classes.Course assessmentCourse = CourseMasterList.GetCurrCourseById(courseID);
string courseName = assessmentCourse != null ? assessmentCourse.CourseName : "";
string type = _sessionObject.AssessmentBuildParms["Type"];
string term = _sessionObject.AssessmentBuildParms["Term"];
courseName = courseName == subject ? "" : courseName;
newAssessmentTitle.Value = "Term " + term + " " + type + " - " + gradeOrdinal.GetFriendlyName() + " Grade " + subject + " " + courseName;
}
示例2: LoadGradeDropdown
private void LoadGradeDropdown()
{
gradeDropdown.Items.Clear();
foreach (Grade grade in _gradeList)
{
RadComboBoxItem item = new RadComboBoxItem();
item.Text = grade.ToString();
item.Value = grade.ToString();
if (grade.ToString() == SelectedImage.Grade)
item.Selected = true;
var gradeOrdinal = new Grade(grade.ToString());
item.Attributes["gradeOrdinal"] = gradeOrdinal.GetFriendlyName();
gradeDropdown.Items.Add(item);
}
}
示例3: LoadGradeButtonFilter
protected void LoadGradeButtonFilter()
{
var gradeListTable = Base.Classes.Teacher.GetGradesForTeacher(teacherID, 0);
gradeList.Items.Clear();
gradeList.Attributes["teacherID"] = teacherID.ToString();
foreach (DataRow dr in gradeListTable.Rows)
{
RadMenuItem gradeListItem = new RadMenuItem(dr["Grade"].ToString());
Grade gradeOrdinal = new Grade(dr["Grade"].ToString());
gradeListItem.Attributes["gradeOrdinal"] = gradeOrdinal.GetFriendlyName();
if (dr["Grade"].ToString() == classGrade)
{
gradeListItem.Selected = true;
gradeButton.Text = dr["Grade"].ToString();
}
gradeListItem.Width = 200;
gradeList.Items.Add(gradeListItem);
}
if (gradeList.SelectedValue.Length == 0 && gradeList.Items.Count == 1)
{
gradeList.Items[0].Selected = true;
gradeButton.Text = gradeList.SelectedValue;
}
}