Inherits System.Windows.Forms.Form
Dim DS1 As New System.Data.DataSet
Dim DS2 As New System.Data.DataSet
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim MyCommand As System.Data.OleDb.OleDbDataAdapter
Dim MyConnection As System.Data.OleDb.OleDbConnection
MyConnection = New System.Data.OleDb.OleDbConnection( _
"provider=Microsoft.Jet.OLEDB.4.0; " & _
"data source=e:\BOOK1.XLS; " & _
"Extended Properties=Excel 8.0;")
' Select the data from Sheet1 of the workbook.
MyCommand = New System.Data.OleDb.OleDbDataAdapter( _
"select * from [Sheet1$]", MyConnection)
'或者是DS1.ReadXml("c:\abcd.xml")
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Try
Dim j As Integer
Dim person_id, information_id, handle As String
Dim handle_time As System.DateTime
'If Me.SqlConnection1.Close() Then
Me.SqlConnection1.Open()
'End If
For j = 1 To DS1.Tables("handle").Rows.Count - 1