المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : How to extract data from DataGridView in csharp smart device?????



C# Programming
04-26-2010, 12:30 AM
Hello everybody,
I develop a GMAO csharp smart device application using Visual studio 2008.I try to show my data stocked in my tables in my database .sdf.I use DataGridView tool.I add in the proprietes of my dataGridView the table i wanna show its data.My DataGridViewForm's code is:
using System;
using System.Linq;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace ModeDifféré
{
public partial class DataGridT : Form
{
public DataGridT()
{
InitializeComponent();
}

private void DataGridT_Load(object sender, EventArgs e)
{
// TODO: This line of code loads data into the 'baseGmaoLocaleDataSet2.Travaux' table. You can move, or remove it, as needed.
this.travauxTableAdapter.Fill(this.baseGmaoLocaleDataSet2.Travaux);

}

private void dataGrid1_CurrentCellChanged(object sender, EventArgs e)
{

}
}
}
But the problem is when running,an error occurs :
The column name is not valid. [ Node name (if any) = ,Column name = Effectué/Non ]what is the problem?
Any help will be very helpful
http://www.barakasoft.com/script/Forums/Images/smiley_smile.gif
Regards