private void xqck_Load(object sender, System.EventArgs e)
{
DataGridTableStyle ts = new DataGridTableStyle();  
ts.AlternatingBackColor = Color.LightGray;
ts.MappingName = this.ds.Tables[0].TableName;
this.dataGrid1.TableStyles.Add(ts);sendStrSQL = "SELECT ID AS 编号, Name FROM tZD where Parent = 0";
this.ds = this.link.SelectDataBase(sendStrSQL,sendTableName);
this.dataGrid1.DataSource = ds;treeView1.BeginUpdate();
for (int i=0;i<ds.Tables[0].Rows.Count;i {
TreeNode node=new TreeNode(ds.Tables [0].Rows [i][1].ToString ().Trim());
treeView1.Nodes.Add(node);
getSubNode(node);}
treeView1.EndUpdate();
}
private void getSubNode(TreeNode PathName)
{
treeView1.BeginUpdate();
PathName.Nodes.Clear();
string strFullPath = PathName.FullPath;
string id = PathName.Tag.ToString();
sendStrSQL = "SELECT ID AS 编号, Name FROM tZD where Parent = " + id;
this.ds = this.link.SelectDataBase(sendStrSQL,sendTableName);
this.dataGrid1.DataSource = ds;for (int i=0;i<ds.Tables[0].Rows.Count;i++)
{
TreeNode node = new TreeNode(ds1.Tables [0].Rows [i][1].ToString().Trim());
node.Tag = ds.Tables [0].Rows [i][0].ToString();
PathName.Nodes.Add("node");

}
treeView1.EndUpdate();
}以上的代码是生成一个目录树,但运行后出现如提的错误提示,请问这是什么错误?如何解决,谢谢