this.cmd1=this.oleDbConnection1.CreateCommand();
this.cmd1.CommandText="select 消息编号,标题,内容 from clientinfotb where 客户编号='zhang1'";
this.oleDbConnection1.Open();
this.oleDbDataAdapter1.SelectCommand = this.cmd1;
this.oleDbDataAdapter1.Fill(this.dataSet11,"clientinfotb");
this.oleDbConnection1.Close();
DataView dv = this.dataSet11.Table[0].DefaultView;
this.DataGrid1.DataSource=dv ;
this.DataGrid1.DataBind();
this.Label1.Text=this.Session["username"].ToString()+"您好!目前您
一共有"+dv.Count+"消息";//我就是想在这里显示出纪录的条数
this.cmd1.CommandText="select 消息编号,标题,内容 from clientinfotb where 客户编号='zhang1'";
this.oleDbConnection1.Open();
this.oleDbDataAdapter1.SelectCommand = this.cmd1;
this.oleDbDataAdapter1.Fill(this.dataSet11,"clientinfotb");
this.oleDbConnection1.Close();
DataView dv = this.dataSet11.Table[0].DefaultView;
this.DataGrid1.DataSource=dv ;
this.DataGrid1.DataBind();
this.Label1.Text=this.Session["username"].ToString()+"您好!目前您
一共有"+dv.Count+"消息";//我就是想在这里显示出纪录的条数
一共有"+ aaa +"消息";//我就是想在这里显示出纪录的条数
this.cmd1=this.oleDbConnection1.CreateCommand();
this.cmd1.CommandText="select count(*) from clientinfotb where 客户编号='zhang1'";
try
{
this.oleDbConnection1.Open();
this.Label1.Text=this.Session["username"].ToString()+"您好!目前您
一共有"+cmd1.ExecuteScalar().ToString()+"消息";//我就是想在这里显示出纪录的条数
}
catch
{
错误提示
}