Quote:
Originally posted by twister002
What happens if you comment out the line "cmd.ExecuteNonQuery();"
Have you put a trace on the database using SQL profiler and see what code is being sent?
|
If you comment it out, nothing will happen, of course, since that's the statement that actually executes the SQL code. I mean, you won't see proof of code still executing unless you check connection logs to see that the db connection was in fact opened, but code is still being executed regardless.
And I'm not sure about what you're asking regarding the trace... the same exact code is being sent as if you were to execute the click event without any breakpoints.
The designer is basically ignoring the fact that you hit "stop" and is executing the code regardless.
Did any of you try it? If so, what were the results?