I want to take SQLCommand and remove ExecuteNonQuery (among others) and
implement my own routine that will do error checking and connection
organization. If I have to I can override the routine but I'd like to remove
it completely so people don't use it by accident.
I'd like to inherit from SQLCommand for all of the things like parameters,
command type, ....
TIA - Jeff
"Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT dot.state.fl.us> wrote
in message news:Ou**************@TK2MSFTNGP02.phx.gbl...
Hi,
Can you give a concrete example?
You can redefine the virtual methods, maybe throwning exception if you dim
it as unnecesary.
"UJ" <fr**@nowhere.com> wrote in message
news:%2******************@TK2MSFTNGP05.phx.gbl...I am going to write a class that will inherit from SqlCommand and I want
to disable certain routines in the SqlCommand and add a couple of new
routines. How would I go about doing that? I understand (I think) the
inheritance process but I'm worried more about the disabling of the
routines. I want to disable certain routines and add my own to do some
special things.
Thanks for the help.
Jeff.