Dim con As New SqlConnection() Dim cmd As New SqlCommand() Dim ds As New DataSet() con.ConnectionString = "接続文字列" Using adapter As New SqlDataAdapter() cmd.Connection = con cmd.CommandText = "SELECT * FROM ..." adapter.SelectCommand = cmd adapter.Fill(ds) End Using Dim dataTable As DataTable = ds.Tables(0)