DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world
ADO.NET Command Object: Adding A New Parameter
There are many ways of adding a new parameter to an ado.net command object. One way is pass parameter and it's data type in one go.
System.Data.SqlClient.SqlParameter param;
param = command.Parameters.Add("@CategoryName", SqlDbType.VarChar, 15);
param.Direction= System.Data.ParameterDirection.Input;
param.Value = cat;





