Private Sub Form_Load() Data1.DatabaseName = App.Path & "\sj.mdb" '設(shè)置連接數(shù)據(jù)庫 Data1.Connect = ";pwd=" & 111 '設(shè)置連接密碼 Data1.RecordSource = "sy" '設(shè)置數(shù)據(jù)表 Data1.Refresh End Sub Private Sub Command1_Click() '移動(dòng)記錄到第一行 If Not Data1.Recordset.BOF Then Data1.Recordset.MoveFirst ' End Sub Private Sub Command2_Click() '移動(dòng)記錄到前一行 If Not Data1.Recordset.BOF Then Data1.Recordset.MovePrevious End Sub Private Sub Command3_Click() '移動(dòng)記錄到后一行 If Not Data1.Recordset.EOF Then Data1.Recordset.MoveNext End Sub Private Sub Command4_Click() '移動(dòng)記錄到最后一行 If Not Data1.Recordset.EOF Then Data1.Recordset.MoveLast End Sub Private Sub Command11_Click() End End Sub