Beruflich Dokumente
Kultur Dokumente
Imports System.Data.OleDb
End If
datafile = "D:\Finals
Thesis\DiazCollegeLibrarySystem\DiazCollegeLibrarySystem\LibraryRecords.accdb"
myconnection.ConnectionString = connstring
While dr.Read
userconfrm = True
End While
End Sub
Application.Exit()
Else
End If
End Sub
End Class
DataGridView1.DataSource = dt.DefaultView
con.Close()
End Sub
con.Open()
con.Close()
dtview = ds.Tables(0).DefaultView
bs.DataSource = dtview
bs.Filter = "UserName LIKE'" & TextBox1.Text & "*' or Password LIKE'" &
TextBox1.Text & "*' or FullName LIKE'" & TextBox1.Text & "*' or Gender LIKE'" &
TextBox1.Text & "*' or Position LIKE'" & TextBox1.Text & "*'"
DataGridView1.DataSource = bs
con.Close()
End Sub
con.Open()
dt.Rows(0).BeginEdit()
dt.Rows(0).Delete()
dt.Rows(0).EndEdit()
da.Update(dt)
DataGridView1.DataSource = dt.DefaultView
con.Close()
Else
End If
End Sub
End Class
End Sub
Me.Validate()
Me.BooksBindingSource.EndEdit()
Me.BooksTableAdapter.Update(Me.LibraryRecordsDataSet)
End Sub
Me.BooksBindingSource.AddNew()
End Sub
Me.BooksBindingSource.RemoveCurrent()
Me.Validate()
Me.BooksBindingSource.EndEdit()
Me.BooksTableAdapter.Update(Me.LibraryRecordsDataSet)
Else
End If
End Sub
With DGV1
fmt.LineAlignment = StringAlignment.Center
fmt.Trimming = StringTrimming.EllipsisCharacter
Dim y As Single = e.MarginBounds.Top
Dim h As Single = 0
If (newpage) Then
e.Graphics.DrawString(DGV1.Columns(cell.ColumnIndex).HeaderText,
.Font, Brushes.Black, rc, fmt)
Else
e.Graphics.DrawString(DGV1.Rows(cell.RowIndex).Cells(cell.ColumnIndex).FormattedValue.ToS
tring(), .Font, Brushes.Black, rc, fmt)
End If
x += rc.Width
h = Math.Max(h, rc.Height)
Next
newpage = False
y += h
mRow += 1
e.HasMorePages = True
mRow -= 1
newpage = True
Exit Sub
End If
Loop
mRow = 0
End With
End Sub
End Class
End Sub
Me.BorrowerRegisterBindingSource.AddNew()
End Sub
Me.Validate()
Me.BorrowerRegisterBindingSource.EndEdit()
Me.BorrowerRegisterTableAdapter.Update(Me.LibraryRecordsDataSet)
End Sub
End Sub
End Class
Me.BorrowedBooksBindingSource.AddNew()
ad.Fill(ta)
DataGridView2.DataSource = ta.DefaultView
con.Close()
Timer1.Start()
TextBox13.Text = Date.Now
TextBox15.Text = Date.Now.AddDays(1)
End Sub
End Sub
con.Open()
con.Close()
dv = d.Tables(0).DefaultView
b.DataSource = dv
b.Filter = " BorrowerID LIKE'" & TextBox2.Text & "*' or FullName LIKE'" &
TextBox2.Text & "*' or Gender LIKE'" & TextBox2.Text & "*' or Department LIKE'" &
TextBox2.Text & "*' or [Course/Position] LIKE'" & TextBox2.Text & "*'or [Grade/Year]
LIKE'" & TextBox2.Text & "*'"
DataGridView2.DataSource = b
con.Close()
End Sub
End Sub
Me.Validate()
Me.BorrowedBooksBindingSource.EndEdit()
Me.BorrowedBooksTableAdapter.Update(Me.LibraryRecordsDataSet)
Me.BorrowedBooksBindingSource.AddNew()
Me.BooksBindingSource.RemoveCurrent()
Me.Validate()
Me.BooksBindingSource.EndEdit()
Me.BooksTableAdapter.Update(Me.LibraryRecordsDataSet)
End If
End Sub
Me.BooksBindingSource.AddNew()
End Sub
End Sub
Me.BooksBindingSource.AddNew()
Me.BorrowedBooksBindingSource.RemoveCurrent()
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Handles Button1.Click
TextBox14.Text = Date.Now
due = 24
d = Val(TextBox15.Text) \ 24
fine = 5
addfine = 1
If TextBox15.Text <= due Then
TextBox16.Text = 0
End If
If TextBox15.Text > due Then
TextBox16.Text = fine + addfine
End If
End Sub