Dear All,
I want to call Stored Procedures Parameters in List instead of AddwithValue Method using SqlCommand Object.
For Example: Generally we call a parameter using SqlCommand object
cmd.Parameters.AddwithValue("@Name",txtname.Text) ;
I want to call parameter in List then we insert the List value int Database.
Please Help me...

Joginder BangerRank #360 · 7K reputationPosted Nov 4, 2014, 3:06 AM EST
SqlParameter[] arParms = new SqlParameter[4];
arParms[0] = new SqlParameter("@UserName", SqlDbType.VarChar, 100);
arParms[0].Value = UserName;
arParms[1] = new SqlParameter("@password", SqlDbType.VarChar, 50);
arParms[1].Value = strgivenpassword;
arParms[2] = new SqlParameter("@succ", SqlDbType.Int);
arParms[2].Direction = ParameterDirection.Output;
arParms[3] = new SqlParameter("@LoginID", SqlDbType.Int);
arParms[3].Direction = ParameterDirection.Output;
Joginder BangerRank #360 · 7K reputationPosted Nov 4, 2014, 3:09 AM EST
amarnath reddy ambati39 reputationPosted Nov 4, 2014, 6:33 PM EST
Riddhi ValechaRank #794 · 2.9K reputationPosted Nov 4, 2014, 8:30 PM EST
cmd.parameters.addwithvalues("@abc","dre");