private void bttnStudentID_Click(object sender, System.EventArgs e) { FORMBarrowers_View.sSY = sSY; FORMBarrowers_View.sLevel = sLevel; FORMBarrowers_View sForm = new FORMBarrowers_View(); sForm.ShowDialog(); }
private void FORMBarrowers_View_Load(object sender, System.EventArgs e) { lvBarrowers.SmallImageList = MDIFORM.i16x16; //Set the Data Adapter daBarrwrList = new OleDbDataAdapter("", clsConnections.CN); loadBooks("SELECT tblBarrowers.BarrowerID, [LastName] & ', ' & [FirstName] & ' ' & [MiddleName] AS Fullname, tblCourse.CourseName, tblLevel.LevelName, [YearStart] & ' - ' & [YearEnd] AS SY FROM tblSchoolYear INNER JOIN (tblLevel INNER JOIN (tblCourse RIGHT JOIN tblBarrowers ON tblCourse.IndexCourse = tblBarrowers.Course) ON tblLevel.IndexLevel = tblBarrowers.LevelIndex) ON tblSchoolYear.IndexSY = tblBarrowers.SchoolYear WHERE [YearStart] & ' - ' & [YearEnd] LIKE '" + sSY + "' AND tblLevel.LevelName LIKE '" + sLevel + "' ORDER BY tblBarrowers.BarrowerID ASC"); publicBarrwrList = this; this.Refresh(); }