Automatic creation of parameters with the SqlDataSource Control
I've recently converted an existing web application from 3.5 to framework 4.0 and noticed a page stopped working - with an "incorrect number of parameters" error.
Page is fairly simple and has a SQLDataSource Control with 3 explicit update parameters:
However there is a textbox on page which is read only, but is set to Bind to another field in datasource - which means auto creation of param开发者_如何学Ceters now expects 4 update parameters.
I have set Bind to Eval to overcome this problem, but I'm worried that this bad practice wasn't picked up in production version running on 3.5.
My question is: Automatic creation of parameters isn't something that was introduced in framework 4.0 - so is it just a case of stricter enforcement of rules causing this to be picked up now?
Worried in case there are other instances of this within web app...
精彩评论