objectDataSource updating - read only dictionary problem
protected void objUpdating(object sender, ObjectDataSourceMethodEventArgs e)
{
e.InputParameters.Add("update_name", "xxx");
}
开发者_开发问答Hi, I am trying to make Update method for ObjectDataSource, which has argument "update_name" but adding parameter to collection using add method throws an exception of dictionary ( key value ) is read only any thougths? thank you
You cannot use Add method as ObjectDataSource has already added a parameter to the collection.
Try
e.InputParameters["update_name"]= "xxx";
that will work
精彩评论