各位高手帮帮忙,小弟刚学VB数据库编程
我建立了一个与外部数据库相连接的程序用到了DataGrid控件和OleDbDataAdapter,OleDbConnection,DataSet
开头的代码如下:
Public Class Form1
Inherits System.Windows.Forms.Form
Public findstr As String
Public Sub UpDataSource(ByVal ChangedRows As DataList1.DataSet1)
Try
If (Not (ChangedRows) Is Nothing) Then
Me.OleDbConnection1.Open()
Me.OleDbDataAdapter1.Update(ChangedRows)
End If
Catch updateException As System.Exception
Throw updateException
Finally
Me.OleDbConnection1.Close()
End Try
End Sub
VB居然说DataList1.DataSet1未声明,请教各位高手是怎么回事,望尽快解答!谢谢!