none
C# Full Join to the table (No work) RRS feed

  • Question

  • This is my code...I want load the data to the datagridciew, but got error when fill data to table

    string view = "select Attendance.Staff_ID,Attendance.DateTime,Attendance.Recognition_Rate,Attendance.Status,Staff.Name from Attendance FULL JOIN Staff ON Attendance.Staff_ID = Staff.Staff_ID";
                OleDbCommand viewcon = new OleDbCommand(view, vcon);
                DataSet vds = new DataSet();
                OleDbDataAdapter vda = new OleDbDataAdapter(viewcon);
                vda.Fill(vds, "res");
                dataGridView1.DataSource = vds.Tables["res"];
                vda.Dispose();
                viewcon.Dispose();

    Sunday, December 30, 2012 8:44 AM

All replies

  • what error?

    Ghost,
    Call me ghost for short, Thanks
    To get the better answer, it should be a better question.

    Monday, December 31, 2012 6:42 AM
  • Yes, we need more information, such as the exception message (error).

    Paul ~~~~ Microsoft MVP (Visual Basic)

    Wednesday, January 2, 2013 2:47 PM