Which SqlCommand gets used (and how to keep VS2005 from complaining that there are two)


hello,

    i adding sql server access application using enterprise library (an older version).

    

    system.data.sqlclient.sqlcommand sqldbcommand = 
            (system.data.sqlclient.
sqlcommand)    sqldb.getstoredproccommand("dbo.get_this_pupil");

    sqldbcommand.parameters.add("thepupil", sqldbtype.varchar, 12).direction = 
                                                                parameterdirection
.input;

    sqldbcommand.parameters["thepupil"].value = pupilid



    when compile, :

error 1 the type 'system.data.sqlclient.sqlcommand' exists in both 'c:\windows\microsoft.net\framework\v2.0.50727\system.data.dll' , 'c:\program files\microsoft visual studio 8\common7\ide\publicassemblies\system.data.sqlclient.dll' c:\documents , settings\mcklapp\my documents\visual studio 2005\projects\grantopsadmin_v2\sesdataaccess\sesdataaccess\services\srappentrydl.cs 80 35 sesdataaccess

thanks

oic - need addinparameter database, not database command.

thank you,


SQL Server  >  SQL Server Data Access



Comments

Popular posts from this blog

more indexes

ActiveDirectory

Virtual Channel