Asp.net| Solution
When ObjectDataSource automatically configures the delete operation for a data source in ASP.net, two fields are generated one is
oldvaluesparameterformatstring= "Original_{0}"
The other one is
<DeleteParameters>
<asp:parameter name= "original_xml_id" type= "Int32"/>
</DeleteParameters>
This oldvaluesparameterformatstring is determined by the parameters in the SQL statement you set, and parameter name is determined by the first parameter that deletes the function in your business ROM base.
For example, your deletion component in the business logic layer is defined in this way, and the first parameter in the function is the ObjectDataSource-generated parameter Name
[System.ComponentModel.DataObjectMethodAttribute (System.ComponentModel.DataObjectMethodType.Delete, True)]
public bool Delxml (int original_xml_id)
{
int rowsaffected = Adapter.delete (original_xml_id);
return rowsaffected = = 1;
}
Here's what you should be aware of. The name of the parameter in the parentheses in the Del function and the name of the parameter in SQL if it is not the same, the "BLL method with parameters could not be found" is a strange error. I don't know if it's a asp.net bug, but it's really annoying. Even Microsoft's official tutorials (see www.asp.net) did not solve the bug.
I searched the solution on the Internet for this problem, and did not find a more detailed one. Fantasia also found a similar problem and referred to his solution.