|
hello all,please help me solve this error... (im using Vb.Net,Sql Server 2005 within Vb.net) when i try to show my table content using datagrid,and also using dataset technique to store the changes temporary before user does the real changes to database.. then i got error that says SetDataBinding is not a member of System.forms.Windows.DataGridView here is my code : Private Sub FrmDbStaff_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load connetionString = "Data Source=.\SQLEXPRESS;AttachDbFilename=C:\Users\Crocketzzz\Documents\Visual Studio 2005\Projects\XXI Cineplex system\XXI Cineplex system\Interface\Database\XXI_Database.mdf;Integrated Security=True;User Instance=True" 'cnn = New SqlConnection(connetionString) Dim data_adapter As SqlDataAdapter ' Create the SqlDataAdapter. data_adapter = New SqlDataAdapter("SELECT * FROM [User]", connetionString) ' Map Table to [User]. data_adapter.TableMappings.Add("Table", "[User]") ' Fill the DataSet. m_DataSet = New DataSet() data_adapter.Fill(m_DataSet) ' Bind the DataGrid control to the Contacts DataTable. dguser.SetDataBinding(m_DataSet, "[User]") my regards - Moved bynobugzMVP, ModeratorSunday, September 06, 2009 11:38 AM (From:.NET Base Class Library)
-
|