table'参数不能为null。参数名称:表格 [英] table' argument cannot be null. Parameter name: table
问题描述
我正在开发一个crm项目,它从crm中检索数据并向他们展示
,这里我们去吧/>
DataTable dt = RetrieveAttendeePersons();
DataSet ds = new DataSet();
ds.Tables.Add (dt);
RadGrid1.DataSource = ds;
RadGrid1.DataBind();
,错误是:table'参数不能为null。参数名称:table,它指向以下行:ds.Tables.Add(dt);
我非常感谢你的帮助。
似乎数据表
是null
,
验证
表格,然后将其添加到数据集中。
< span class =code-keyword> if (dt!= null )
ds.Tables.Add(dt);
Hi ,
I am working on a crm project which retrieve data from crm and show them
, here we go
DataTable dt = RetrieveAttendeePersons();
DataSet ds = new DataSet();
ds.Tables.Add(dt);
RadGrid1.DataSource = ds;
RadGrid1.DataBind();
and the error is : table' argument cannot be null. Parameter name: table and it points to the following line : ds.Tables.Add(dt);
I would really appreciate your help .
It Seems thedatatable
isnull
,
validate
the table before adding it to a dataset.
if(dt!= null) ds.Tables.Add(dt);
这篇关于table'参数不能为null。参数名称:表格的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!